@@ -20,7 +20,7 @@ discard block |
||
20 | 20 | $this->list = new FormValuesConsumerList($form, $consumer); |
21 | 21 | } |
22 | 22 | |
23 | - public static function for($form, $consumer) |
|
23 | + public static function for ($form, $consumer) |
|
24 | 24 | { |
25 | 25 | return new static($form, $consumer); |
26 | 26 | } |
@@ -50,9 +50,9 @@ discard block |
||
50 | 50 | |
51 | 51 | return [ |
52 | 52 | 'where' => [ |
53 | - ['id_form = ?', $this->list->getForm()->id,], |
|
54 | - ['consumer = ?', $consumer->getManager()->getMorphName(),], |
|
55 | - ['consumer_id = ?', $consumer->id,], |
|
53 | + ['id_form = ?', $this->list->getForm()->id, ], |
|
54 | + ['consumer = ?', $consumer->getManager()->getMorphName(), ], |
|
55 | + ['consumer_id = ?', $consumer->id, ], |
|
56 | 56 | ], |
57 | 57 | ]; |
58 | 58 | } |
@@ -40,7 +40,7 @@ |
||
40 | 40 | |
41 | 41 | public function bootFormTrait() |
42 | 42 | { |
43 | - $this->addCast('metadata', AsMetadataObject::class.':json'); |
|
43 | + $this->addCast('metadata', AsMetadataObject::class . ':json'); |
|
44 | 44 | } |
45 | 45 | |
46 | 46 | public function setConsumerClass($consumerClass) |
@@ -10,7 +10,7 @@ |
||
10 | 10 | { |
11 | 11 | use HasSubject; |
12 | 12 | |
13 | - protected Form|null $source = null; |
|
13 | + protected Form | null $source = null; |
|
14 | 14 | |
15 | 15 | |
16 | 16 | public function handle() |
@@ -36,8 +36,8 @@ |
||
36 | 36 | { |
37 | 37 | $sourceForm = FormGenerateForConsumer::for($consumer)->handle(); |
38 | 38 | $this->getSubject()->addImportLink([ |
39 | - 'name' => $consumer->getName(), |
|
40 | - 'href' => $this->generateImportLink($this->form, $sourceForm), |
|
39 | + 'name' => $consumer->getName(), |
|
40 | + 'href' => $this->generateImportLink($this->form, $sourceForm), |
|
41 | 41 | ]); |
42 | 42 | } |
43 | 43 |
@@ -34,7 +34,7 @@ discard block |
||
34 | 34 | |
35 | 35 | protected function addDesignerImportLink($consumer) |
36 | 36 | { |
37 | - $sourceForm = FormGenerateForConsumer::for($consumer)->handle(); |
|
37 | + $sourceForm = FormGenerateForConsumer::for ($consumer)->handle(); |
|
38 | 38 | $this->getSubject()->addImportLink([ |
39 | 39 | 'name' => $consumer->getName(), |
40 | 40 | 'href' => $this->generateImportLink($this->form, $sourceForm), |
@@ -43,6 +43,6 @@ discard block |
||
43 | 43 | |
44 | 44 | protected function generateImportLink($form, $sourceForm) |
45 | 45 | { |
46 | - return $form->compileUrl('import',['form_id' => $sourceForm->id]); |
|
46 | + return $form->compileUrl('import', ['form_id' => $sourceForm->id]); |
|
47 | 47 | } |
48 | 48 | } |
49 | 49 | \ No newline at end of file |
@@ -34,7 +34,9 @@ |
||
34 | 34 | |
35 | 35 | protected function addDesignerImportLink($consumer) |
36 | 36 | { |
37 | - $sourceForm = FormGenerateForConsumer::for($consumer)->handle(); |
|
37 | + $sourceForm = FormGenerateForConsumer::for($consumer) { |
|
38 | + ->handle(); |
|
39 | + } |
|
38 | 40 | $this->getSubject()->addImportLink([ |
39 | 41 | 'name' => $consumer->getName(), |
40 | 42 | 'href' => $this->generateImportLink($this->form, $sourceForm), |
@@ -73,7 +73,7 @@ discard block |
||
73 | 73 | $this->flashRedirect($this->getModelManager()->getMessage('import.error'), $form->getURL(), 'error'); |
74 | 74 | } |
75 | 75 | |
76 | - ImportForm::for($form)->withSource($fromForm)->handle(); |
|
76 | + ImportForm::for ($form)->withSource($fromForm)->handle(); |
|
77 | 77 | |
78 | 78 | $this->flashRedirect($this->getModelManager()->getMessage('import.success'), $redirect); |
79 | 79 | } |
@@ -89,7 +89,7 @@ discard block |
||
89 | 89 | protected function bootFormbuilderFormsControllerTrait() |
90 | 90 | { |
91 | 91 | $this->after( |
92 | - function () { |
|
92 | + function() { |
|
93 | 93 | $this->registerFormbuilderViewPaths(); |
94 | 94 | } |
95 | 95 | ); |
@@ -73,7 +73,9 @@ |
||
73 | 73 | $this->flashRedirect($this->getModelManager()->getMessage('import.error'), $form->getURL(), 'error'); |
74 | 74 | } |
75 | 75 | |
76 | - ImportForm::for($form)->withSource($fromForm)->handle(); |
|
76 | + ImportForm::for($form) { |
|
77 | + ->withSource($fromForm)->handle(); |
|
78 | + } |
|
77 | 79 | |
78 | 80 | $this->flashRedirect($this->getModelManager()->getMessage('import.success'), $redirect); |
79 | 81 | } |