21
21
22
22
/**
23
23
* Job to store form submissions
24
- *
24
+ *
25
25
* This job handles the storage of form submissions, including processing of metadata
26
26
* and special field types like files and signatures.
27
- *
27
+ *
28
28
* The job accepts all data in the submissionData array, including metadata fields:
29
29
* - submission_id: ID of an existing submission to update (must be an integer)
30
30
* - completion_time: Time in seconds it took to complete the form
31
31
* - is_partial: Whether this is a partial submission (will be stored with STATUS_PARTIAL)
32
32
* If not specified, submissions are treated as complete by default.
33
- *
33
+ *
34
34
* These metadata fields will be automatically extracted and removed from the stored form data.
35
- *
35
+ *
36
36
* For partial submissions:
37
37
* - The submission will be stored with STATUS_PARTIAL
38
38
* - All file uploads and signatures will be processed normally
@@ -57,7 +57,9 @@ class StoreFormSubmissionJob implements ShouldQueue
57
57
* @param array $submissionData Form data including metadata fields (submission_id, completion_time, etc.)
58
58
* @return void
59
59
*/
60
- public function __construct (public Form $ form , public array $ submissionData ) {}
60
+ public function __construct (public Form $ form , public array $ submissionData )
61
+ {
62
+ }
61
63
62
64
/**
63
65
* Execute the job.
@@ -87,7 +89,7 @@ public function handle()
87
89
88
90
/**
89
91
* Extract metadata from submission data
90
- *
92
+ *
91
93
* This method extracts and removes metadata fields from the submission data:
92
94
* - submission_id
93
95
* - completion_time
@@ -128,7 +130,7 @@ public function getSubmissionId()
128
130
129
131
/**
130
132
* Store the submission in the database
131
- *
133
+ *
132
134
* @param array $formData
133
135
*/
134
136
private function storeSubmission (array $ formData )
@@ -318,7 +320,7 @@ private function addHiddenPrefills(array &$formData): void
318
320
319
321
/**
320
322
* Get the processed form data including the submission ID
321
- *
323
+ *
322
324
* @return array
323
325
*/
324
326
public function getProcessedData (): array
0 commit comments