@@ -57,7 +57,7 @@ discard block |
||
57 | 57 | |
58 | 58 | public function __toString() |
59 | 59 | { |
60 | - return (string)$this->name; |
|
60 | + return (string) $this->name; |
|
61 | 61 | } |
62 | 62 | |
63 | 63 | /** |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | */ |
66 | 66 | public function getId(): int |
67 | 67 | { |
68 | - return (int)$this->id; |
|
68 | + return (int) $this->id; |
|
69 | 69 | } |
70 | 70 | |
71 | 71 | /** |
@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | */ |
84 | 84 | public function getExternalId(): int |
85 | 85 | { |
86 | - return (int)$this->externalId; |
|
86 | + return (int) $this->externalId; |
|
87 | 87 | } |
88 | 88 | |
89 | 89 | /** |
@@ -70,7 +70,7 @@ discard block |
||
70 | 70 | |
71 | 71 | public function __toString() |
72 | 72 | { |
73 | - return (string)$this->name; |
|
73 | + return (string) $this->name; |
|
74 | 74 | } |
75 | 75 | |
76 | 76 | /** |
@@ -78,7 +78,7 @@ discard block |
||
78 | 78 | */ |
79 | 79 | public function getId(): int |
80 | 80 | { |
81 | - return (int)$this->id; |
|
81 | + return (int) $this->id; |
|
82 | 82 | } |
83 | 83 | |
84 | 84 | /** |
@@ -96,7 +96,7 @@ discard block |
||
96 | 96 | */ |
97 | 97 | public function getExternalId(): string |
98 | 98 | { |
99 | - return (string)$this->externalId; |
|
99 | + return (string) $this->externalId; |
|
100 | 100 | } |
101 | 101 | |
102 | 102 | /** |
@@ -57,7 +57,7 @@ discard block |
||
57 | 57 | |
58 | 58 | public function __toString() |
59 | 59 | { |
60 | - return (string)$this->name; |
|
60 | + return (string) $this->name; |
|
61 | 61 | } |
62 | 62 | |
63 | 63 | /** |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | */ |
66 | 66 | public function getId(): int |
67 | 67 | { |
68 | - return (int)$this->id; |
|
68 | + return (int) $this->id; |
|
69 | 69 | } |
70 | 70 | |
71 | 71 | /** |
@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | */ |
84 | 84 | public function getExternalId(): int |
85 | 85 | { |
86 | - return (int)$this->externalId; |
|
86 | + return (int) $this->externalId; |
|
87 | 87 | } |
88 | 88 | |
89 | 89 | /** |
@@ -57,7 +57,7 @@ discard block |
||
57 | 57 | |
58 | 58 | public function __toString() |
59 | 59 | { |
60 | - return (string)$this->name; |
|
60 | + return (string) $this->name; |
|
61 | 61 | } |
62 | 62 | |
63 | 63 | /** |
@@ -65,7 +65,7 @@ discard block |
||
65 | 65 | */ |
66 | 66 | public function getId(): int |
67 | 67 | { |
68 | - return (int)$this->id; |
|
68 | + return (int) $this->id; |
|
69 | 69 | } |
70 | 70 | |
71 | 71 | /** |
@@ -83,7 +83,7 @@ discard block |
||
83 | 83 | */ |
84 | 84 | public function getExternalId(): int |
85 | 85 | { |
86 | - return (int)$this->externalId; |
|
86 | + return (int) $this->externalId; |
|
87 | 87 | } |
88 | 88 | |
89 | 89 | /** |
@@ -95,7 +95,7 @@ discard block |
||
95 | 95 | */ |
96 | 96 | public function getId(): int |
97 | 97 | { |
98 | - return (int)$this->id; |
|
98 | + return (int) $this->id; |
|
99 | 99 | } |
100 | 100 | |
101 | 101 | /** |
@@ -113,7 +113,7 @@ discard block |
||
113 | 113 | */ |
114 | 114 | public function getIdentifier(): string |
115 | 115 | { |
116 | - return (string)$this->identifier; |
|
116 | + return (string) $this->identifier; |
|
117 | 117 | } |
118 | 118 | |
119 | 119 | /** |
@@ -131,7 +131,7 @@ discard block |
||
131 | 131 | */ |
132 | 132 | public function getType(): string |
133 | 133 | { |
134 | - return (string)$this->type; |
|
134 | + return (string) $this->type; |
|
135 | 135 | } |
136 | 136 | |
137 | 137 | /** |
@@ -149,7 +149,7 @@ discard block |
||
149 | 149 | */ |
150 | 150 | public function getStatus(): string |
151 | 151 | { |
152 | - return (string)$this->status; |
|
152 | + return (string) $this->status; |
|
153 | 153 | } |
154 | 154 | |
155 | 155 | /** |
@@ -403,7 +403,7 @@ discard block |
||
403 | 403 | |
404 | 404 | public function __toString() |
405 | 405 | { |
406 | - return (string)$this->number; |
|
406 | + return (string) $this->number; |
|
407 | 407 | } |
408 | 408 | |
409 | 409 | /** |
@@ -482,7 +482,7 @@ discard block |
||
482 | 482 | |
483 | 483 | public function hasManufacturer(ManufacturerInterface $manufacturer) : bool |
484 | 484 | { |
485 | - return $this->manufacturers->exists(function ($key, ManufacturerInterface $element) use ($manufacturer) { |
|
485 | + return $this->manufacturers->exists(function($key, ManufacturerInterface $element) use ($manufacturer) { |
|
486 | 486 | return $element->getExternalId() === $manufacturer->getExternalId(); |
487 | 487 | }); |
488 | 488 | } |
@@ -507,7 +507,7 @@ discard block |
||
507 | 507 | $variantGroup = $variantGroup->getExternalId(); |
508 | 508 | } |
509 | 509 | |
510 | - return $this->variantGroups->exists(function ($key, VariantGroupInterface $element) use ($variantGroup) { |
|
510 | + return $this->variantGroups->exists(function($key, VariantGroupInterface $element) use ($variantGroup) { |
|
511 | 511 | return $element->getExternalId() === $variantGroup; |
512 | 512 | }); |
513 | 513 | } |
@@ -570,7 +570,7 @@ discard block |
||
570 | 570 | $product = $product->getExternalId(); |
571 | 571 | } |
572 | 572 | |
573 | - return $this->children->exists(function ($key, ProductInterface $element) use ($product) { |
|
573 | + return $this->children->exists(function($key, ProductInterface $element) use ($product) { |
|
574 | 574 | return $element->getExternalId() === $product; |
575 | 575 | }); |
576 | 576 | } |
@@ -583,7 +583,7 @@ discard block |
||
583 | 583 | */ |
584 | 584 | public function getId(): int |
585 | 585 | { |
586 | - return (int)$this->id; |
|
586 | + return (int) $this->id; |
|
587 | 587 | } |
588 | 588 | |
589 | 589 | /** |
@@ -601,7 +601,7 @@ discard block |
||
601 | 601 | */ |
602 | 602 | public function getExternalId(): int |
603 | 603 | { |
604 | - return (int)$this->externalId; |
|
604 | + return (int) $this->externalId; |
|
605 | 605 | } |
606 | 606 | |
607 | 607 | /** |
@@ -997,7 +997,7 @@ discard block |
||
997 | 997 | */ |
998 | 998 | public function getNumber() |
999 | 999 | { |
1000 | - return (string)$this->number; |
|
1000 | + return (string) $this->number; |
|
1001 | 1001 | } |
1002 | 1002 | |
1003 | 1003 | /** |
@@ -153,7 +153,7 @@ discard block |
||
153 | 153 | |
154 | 154 | $multiplier = BigDecimal::of('100')->plus($this->vatPct)->exactlyDividedBy('100'); |
155 | 155 | |
156 | - return $unitPrice->multiply((string)$multiplier); |
|
156 | + return $unitPrice->multiply((string) $multiplier); |
|
157 | 157 | } |
158 | 158 | |
159 | 159 | public function getUnitPriceExclVat() : ?Money |
@@ -170,7 +170,7 @@ discard block |
||
170 | 170 | |
171 | 171 | $multiplier = BigDecimal::of('100')->plus($this->vatPct)->exactlyDividedBy('100'); |
172 | 172 | |
173 | - return $totalPrice->multiply((string)$multiplier); |
|
173 | + return $totalPrice->multiply((string) $multiplier); |
|
174 | 174 | } |
175 | 175 | |
176 | 176 | public function getTotalPriceExclVat() : ?Money |
@@ -183,7 +183,7 @@ discard block |
||
183 | 183 | */ |
184 | 184 | public function getId(): int |
185 | 185 | { |
186 | - return (int)$this->id; |
|
186 | + return (int) $this->id; |
|
187 | 187 | } |
188 | 188 | |
189 | 189 | /** |
@@ -201,7 +201,7 @@ discard block |
||
201 | 201 | */ |
202 | 202 | public function getExternalId(): int |
203 | 203 | { |
204 | - return (int)$this->externalId; |
|
204 | + return (int) $this->externalId; |
|
205 | 205 | } |
206 | 206 | |
207 | 207 | /** |
@@ -291,7 +291,7 @@ discard block |
||
291 | 291 | */ |
292 | 292 | public function getTotalPrice() |
293 | 293 | { |
294 | - return DandomainFoundation\createMoney($this->getCurrencyCode(), (int)$this->totalPrice); |
|
294 | + return DandomainFoundation\createMoney($this->getCurrencyCode(), (int) $this->totalPrice); |
|
295 | 295 | } |
296 | 296 | |
297 | 297 | /** |
@@ -310,7 +310,7 @@ discard block |
||
310 | 310 | */ |
311 | 311 | public function getUnitPrice() |
312 | 312 | { |
313 | - return DandomainFoundation\createMoney($this->getCurrencyCode(), (int)$this->unitPrice); |
|
313 | + return DandomainFoundation\createMoney($this->getCurrencyCode(), (int) $this->unitPrice); |
|
314 | 314 | } |
315 | 315 | |
316 | 316 | /** |
@@ -30,7 +30,7 @@ discard block |
||
30 | 30 | */ |
31 | 31 | function createMoneyFromFloat(string $currency, $amount = 0.0) : ?Money |
32 | 32 | { |
33 | - $amount = BigDecimal::of((string)round($amount, 2))->multipliedBy(100)->toInt(); |
|
33 | + $amount = BigDecimal::of((string) round($amount, 2))->multipliedBy(100)->toInt(); |
|
34 | 34 | return createMoney($currency, $amount); |
35 | 35 | } |
36 | 36 | |
@@ -40,5 +40,5 @@ discard block |
||
40 | 40 | $obj = json_decode(json_encode($obj), true); |
41 | 41 | } |
42 | 42 | |
43 | - return (array)$obj; |
|
43 | + return (array) $obj; |
|
44 | 44 | } |
@@ -381,7 +381,7 @@ discard block |
||
381 | 381 | |
382 | 382 | $multiplier = BigDecimal::of('100')->exactlyDividedBy(BigDecimal::of('100')->plus($this->vatPct)); |
383 | 383 | |
384 | - return $totalPrice->multiply((string)$multiplier); |
|
384 | + return $totalPrice->multiply((string) $multiplier); |
|
385 | 385 | } |
386 | 386 | |
387 | 387 | public function totalPriceWithoutFees() : ?Money |
@@ -427,7 +427,7 @@ discard block |
||
427 | 427 | $orderLine = $orderLine->getExternalId(); |
428 | 428 | } |
429 | 429 | |
430 | - return $this->orderLines->exists(function ($key, OrderLineInterface $element) use ($orderLine) { |
|
430 | + return $this->orderLines->exists(function($key, OrderLineInterface $element) use ($orderLine) { |
|
431 | 431 | return $element->getExternalId() === $orderLine; |
432 | 432 | }); |
433 | 433 | } |
@@ -485,7 +485,7 @@ discard block |
||
485 | 485 | */ |
486 | 486 | public function getTotalPrice() : ?Money |
487 | 487 | { |
488 | - return $this->createMoney((int)$this->totalPrice); |
|
488 | + return $this->createMoney((int) $this->totalPrice); |
|
489 | 489 | } |
490 | 490 | |
491 | 491 | /** |
@@ -504,7 +504,7 @@ discard block |
||
504 | 504 | */ |
505 | 505 | public function getSalesDiscount() : ?Money |
506 | 506 | { |
507 | - return $this->createMoney((int)$this->salesDiscount); |
|
507 | + return $this->createMoney((int) $this->salesDiscount); |
|
508 | 508 | } |
509 | 509 | |
510 | 510 | /** |
@@ -523,7 +523,7 @@ discard block |
||
523 | 523 | */ |
524 | 524 | public function getGiftCertificateAmount() : ?Money |
525 | 525 | { |
526 | - return $this->createMoney((int)$this->giftCertificateAmount); |
|
526 | + return $this->createMoney((int) $this->giftCertificateAmount); |
|
527 | 527 | } |
528 | 528 | |
529 | 529 | /** |
@@ -542,7 +542,7 @@ discard block |
||
542 | 542 | */ |
543 | 543 | public function getShippingMethodFee() : ?Money |
544 | 544 | { |
545 | - return $this->createMoney((int)$this->shippingMethodFee); |
|
545 | + return $this->createMoney((int) $this->shippingMethodFee); |
|
546 | 546 | } |
547 | 547 | |
548 | 548 | /** |
@@ -561,7 +561,7 @@ discard block |
||
561 | 561 | */ |
562 | 562 | public function getPaymentMethodFee() : ?Money |
563 | 563 | { |
564 | - return $this->createMoney((int)$this->paymentMethodFee); |
|
564 | + return $this->createMoney((int) $this->paymentMethodFee); |
|
565 | 565 | } |
566 | 566 | |
567 | 567 | /** |
@@ -580,7 +580,7 @@ discard block |
||
580 | 580 | */ |
581 | 581 | public function getId(): int |
582 | 582 | { |
583 | - return (int)$this->id; |
|
583 | + return (int) $this->id; |
|
584 | 584 | } |
585 | 585 | |
586 | 586 | /** |
@@ -598,7 +598,7 @@ discard block |
||
598 | 598 | */ |
599 | 599 | public function getExternalId(): int |
600 | 600 | { |
601 | - return (int)$this->externalId; |
|
601 | + return (int) $this->externalId; |
|
602 | 602 | } |
603 | 603 | |
604 | 604 | /** |