@@ -9,12 +9,12 @@ |
||
9 | 9 | |
10 | 10 | interface ProductQuantityEvents |
11 | 11 | { |
12 | - /** |
|
13 | - * Specification |
|
14 | - * - This event is used for product_quantity publishing. |
|
15 | - * |
|
16 | - * @api |
|
17 | - */ |
|
12 | + /** |
|
13 | + * Specification |
|
14 | + * - This event is used for product_quantity publishing. |
|
15 | + * |
|
16 | + * @api |
|
17 | + */ |
|
18 | 18 | public const PRODUCT_QUANTITY_PUBLISH = 'ProductQuantity.product_quantity.publish'; |
19 | 19 | |
20 | 20 | /** |
@@ -42,7 +42,7 @@ |
||
42 | 42 | */ |
43 | 43 | public function install(): void |
44 | 44 | { |
45 | - $this->getTransactionHandler()->handleTransaction(function () { |
|
45 | + $this->getTransactionHandler()->handleTransaction(function() { |
|
46 | 46 | $this->executeInstallTransaction(); |
47 | 47 | }); |
48 | 48 | } |
@@ -560,7 +560,7 @@ |
||
560 | 560 | |
561 | 561 | $useStatements = array_keys($useStatements); |
562 | 562 | sort($useStatements); |
563 | - $useStatements = array_reduce($useStatements, function ($prevUseStatement, $useStatement) { |
|
563 | + $useStatements = array_reduce($useStatements, function($prevUseStatement, $useStatement) { |
|
564 | 564 | return $prevUseStatement . PHP_EOL . 'use ' . $useStatement . ';'; |
565 | 565 | }, ''); |
566 | 566 |
@@ -42,7 +42,7 @@ |
||
42 | 42 | */ |
43 | 43 | public function install(): void |
44 | 44 | { |
45 | - $this->getTransactionHandler()->handleTransaction(function () { |
|
45 | + $this->getTransactionHandler()->handleTransaction(function() { |
|
46 | 46 | $this->executeInstallTransaction(); |
47 | 47 | }); |
48 | 48 | } |
@@ -405,12 +405,12 @@ |
||
405 | 405 | protected function createMoneyModelTransformer() |
406 | 406 | { |
407 | 407 | return new CallbackTransformer( |
408 | - function ($value) { |
|
408 | + function($value) { |
|
409 | 409 | if ($value !== null) { |
410 | 410 | return $value / 100; |
411 | 411 | } |
412 | 412 | }, |
413 | - function ($value) { |
|
413 | + function($value) { |
|
414 | 414 | if ($value !== null) { |
415 | 415 | return $value * 100; |
416 | 416 | } |
@@ -76,12 +76,12 @@ |
||
76 | 76 | protected function createMoneyModelTransformer() |
77 | 77 | { |
78 | 78 | return new CallbackTransformer( |
79 | - function ($value) { |
|
79 | + function($value) { |
|
80 | 80 | if ($value !== null) { |
81 | 81 | return $value / 100; |
82 | 82 | } |
83 | 83 | }, |
84 | - function ($value) { |
|
84 | + function($value) { |
|
85 | 85 | return $value * 100; |
86 | 86 | } |
87 | 87 | ); |
@@ -32,6 +32,6 @@ |
||
32 | 32 | */ |
33 | 33 | public function recalculate(CalculableObjectTransfer $calculableObjectTransfer) |
34 | 34 | { |
35 | - $this->getFacade()->aggregateOfferItemSubtotal($calculableObjectTransfer); |
|
35 | + $this->getFacade()->aggregateOfferItemSubtotal($calculableObjectTransfer); |
|
36 | 36 | } |
37 | 37 | } |
@@ -113,10 +113,10 @@ discard block |
||
113 | 113 | |
114 | 114 | $builder->get(static::FIELD_PRODUCT_POSITION) |
115 | 115 | ->addModelTransformer(new CallbackTransformer( |
116 | - function ($productAbstractIds = null) { |
|
116 | + function($productAbstractIds = null) { |
|
117 | 117 | return $this->getFactory()->getUtilEncodingService()->encodeJson((array)$productAbstractIds); |
118 | 118 | }, |
119 | - function ($productAbstractIds = '{}') { |
|
119 | + function($productAbstractIds = '{}') { |
|
120 | 120 | return $this->getFactory()->getUtilEncodingService()->decodeJson($productAbstractIds, true); |
121 | 121 | } |
122 | 122 | )); |
@@ -193,10 +193,10 @@ discard block |
||
193 | 193 | protected function createProductAbstractIdsFieldTransformer() |
194 | 194 | { |
195 | 195 | return new CallbackTransformer( |
196 | - function (?array $productAbstractIds = null) { |
|
196 | + function(?array $productAbstractIds = null) { |
|
197 | 197 | return implode(',', (array)$productAbstractIds); |
198 | 198 | }, |
199 | - function ($productAbstractIds = '') { |
|
199 | + function($productAbstractIds = '') { |
|
200 | 200 | return $productAbstractIds ? explode(',', $productAbstractIds) : []; |
201 | 201 | } |
202 | 202 | ); |
@@ -17,7 +17,7 @@ |
||
17 | 17 | public function getBarcodePluginMock(): BarcodeGeneratorPluginInterface |
18 | 18 | { |
19 | 19 | return Stub::makeEmpty(BarcodeGeneratorPluginInterface::class, [ |
20 | - 'generate' => function (string $text): BarcodeResponseTransfer { |
|
20 | + 'generate' => function(string $text): BarcodeResponseTransfer { |
|
21 | 21 | return (new BarcodeResponseTransfer()) |
22 | 22 | ->setCode($text) |
23 | 23 | ->setEncoding(static::GENERATED_ENCODING); |