@@ -17,7 +17,6 @@ |
||
17 | 17 | use Sylius\Component\Core\Model\OrderInterface; |
18 | 18 | use Sylius\Component\Core\Model\OrderItemInterface; |
19 | 19 | use Sylius\Component\Order\Modifier\OrderModifierInterface; |
20 | -use Sylius\Component\Order\Processor\OrderProcessorInterface; |
|
21 | 20 | use Sylius\Component\Order\Repository\OrderItemRepositoryInterface; |
22 | 21 | use Symfony\Component\Messenger\Handler\MessageHandlerInterface; |
23 | 22 | use Webmozart\Assert\Assert; |
@@ -18,5 +18,8 @@ |
||
18 | 18 | /** @experimental */ |
19 | 19 | interface UserContextInterface |
20 | 20 | { |
21 | + /** |
|
22 | + * @return null|UserInterface |
|
23 | + */ |
|
21 | 24 | public function getUser(): ?UserInterface; |
22 | 25 | } |
@@ -16,10 +16,7 @@ discard block |
||
16 | 16 | use Sylius\Bundle\ResourceBundle\Form\Type\AbstractResourceType; |
17 | 17 | use Sylius\Bundle\UserBundle\Form\UserVerifiedAtToBooleanTransformer; |
18 | 18 | use Sylius\Component\Core\Model\ShopUser; |
19 | -use Symfony\Component\Form\CallbackTransformer; |
|
20 | 19 | use Symfony\Component\Form\Extension\Core\Type\CheckboxType; |
21 | -use Symfony\Component\Form\Extension\Core\Type\DateTimeType; |
|
22 | -use Symfony\Component\Form\Extension\Core\Type\DateType; |
|
23 | 20 | use Symfony\Component\Form\Extension\Core\Type\EmailType; |
24 | 21 | use Symfony\Component\Form\Extension\Core\Type\PasswordType; |
25 | 22 | use Symfony\Component\Form\Extension\Core\Type\TextType; |
@@ -28,7 +25,6 @@ discard block |
||
28 | 25 | use Symfony\Component\Form\FormEvents; |
29 | 26 | use Symfony\Component\Form\FormInterface; |
30 | 27 | use Symfony\Component\OptionsResolver\OptionsResolver; |
31 | -use Webmozart\Assert\Assert; |
|
32 | 28 | |
33 | 29 | abstract class UserType extends AbstractResourceType |
34 | 30 | { |
@@ -56,7 +56,7 @@ |
||
56 | 56 | |
57 | 57 | $builder->get('verifiedAt')->addModelTransformer(new UserVerifiedAtToBooleanTransformer(), true); |
58 | 58 | |
59 | - $builder->addEventListener(FormEvents::POST_SET_DATA, static function(FormEvent $event) { |
|
59 | + $builder->addEventListener(FormEvents::POST_SET_DATA, static function (FormEvent $event) { |
|
60 | 60 | /** @var ShopUser|null $data */ |
61 | 61 | $data = $event->getData(); |
62 | 62 | if (null === $data) { |
@@ -15,6 +15,9 @@ |
||
15 | 15 | |
16 | 16 | class ChannelNotFoundException extends \RuntimeException |
17 | 17 | { |
18 | + /** |
|
19 | + * @param \UnexpectedValueException $previousException |
|
20 | + */ |
|
18 | 21 | public function __construct($messageOrPreviousException = null, ?\Throwable $previousException = null) |
19 | 22 | { |
20 | 23 | $message = 'Channel could not be found! Tip: You can use the Web Debug Toolbar to switch between channels in development.'; |
@@ -27,52 +27,115 @@ discard block |
||
27 | 27 | CurrenciesAwareInterface, |
28 | 28 | LocalesAwareInterface |
29 | 29 | { |
30 | + /** |
|
31 | + * @return CurrencyInterface |
|
32 | + */ |
|
30 | 33 | public function getBaseCurrency(): ?CurrencyInterface; |
31 | 34 | |
35 | + /** |
|
36 | + * @return void |
|
37 | + */ |
|
32 | 38 | public function setBaseCurrency(?CurrencyInterface $currency): void; |
33 | 39 | |
40 | + /** |
|
41 | + * @return LocaleInterface |
|
42 | + */ |
|
34 | 43 | public function getDefaultLocale(): ?LocaleInterface; |
35 | 44 | |
45 | + /** |
|
46 | + * @return void |
|
47 | + */ |
|
36 | 48 | public function setDefaultLocale(?LocaleInterface $locale): void; |
37 | 49 | |
50 | + /** |
|
51 | + * @return ZoneInterface |
|
52 | + */ |
|
38 | 53 | public function getDefaultTaxZone(): ?ZoneInterface; |
39 | 54 | |
55 | + /** |
|
56 | + * @return void |
|
57 | + */ |
|
40 | 58 | public function setDefaultTaxZone(?ZoneInterface $defaultTaxZone): void; |
41 | 59 | |
60 | + /** |
|
61 | + * @return string |
|
62 | + */ |
|
42 | 63 | public function getTaxCalculationStrategy(): ?string; |
43 | 64 | |
65 | + /** |
|
66 | + * @return void |
|
67 | + */ |
|
44 | 68 | public function setTaxCalculationStrategy(?string $taxCalculationStrategy): void; |
45 | 69 | |
70 | + /** |
|
71 | + * @return string |
|
72 | + */ |
|
46 | 73 | public function getThemeName(): ?string; |
47 | 74 | |
75 | + /** |
|
76 | + * @return void |
|
77 | + */ |
|
48 | 78 | public function setThemeName(?string $themeName): void; |
49 | 79 | |
80 | + /** |
|
81 | + * @return string |
|
82 | + */ |
|
50 | 83 | public function getContactEmail(): ?string; |
51 | 84 | |
85 | + /** |
|
86 | + * @return void |
|
87 | + */ |
|
52 | 88 | public function setContactEmail(?string $contactEmail): void; |
53 | 89 | |
90 | + /** |
|
91 | + * @return string|null |
|
92 | + */ |
|
54 | 93 | public function getContactPhoneNumber(): ?string; |
55 | 94 | |
95 | + /** |
|
96 | + * @return void |
|
97 | + */ |
|
56 | 98 | public function setContactPhoneNumber(?string $contactPhoneNumber): void; |
57 | 99 | |
58 | 100 | public function isSkippingShippingStepAllowed(): bool; |
59 | 101 | |
102 | + /** |
|
103 | + * @return void |
|
104 | + */ |
|
60 | 105 | public function setSkippingShippingStepAllowed(bool $skippingShippingStepAllowed): void; |
61 | 106 | |
62 | 107 | public function isSkippingPaymentStepAllowed(): bool; |
63 | 108 | |
109 | + /** |
|
110 | + * @return void |
|
111 | + */ |
|
64 | 112 | public function setSkippingPaymentStepAllowed(bool $skippingPaymentStepAllowed): void; |
65 | 113 | |
66 | 114 | public function isAccountVerificationRequired(): bool; |
67 | 115 | |
116 | + /** |
|
117 | + * @return void |
|
118 | + */ |
|
68 | 119 | public function setAccountVerificationRequired(bool $accountVerificationRequired): void; |
69 | 120 | |
121 | + /** |
|
122 | + * @return ShopBillingDataInterface|null |
|
123 | + */ |
|
70 | 124 | public function getShopBillingData(): ?ShopBillingDataInterface; |
71 | 125 | |
126 | + /** |
|
127 | + * @return void |
|
128 | + */ |
|
72 | 129 | public function setShopBillingData(ShopBillingDataInterface $shopBillingData): void; |
73 | 130 | |
131 | + /** |
|
132 | + * @return TaxonInterface|null |
|
133 | + */ |
|
74 | 134 | public function getMenuTaxon(): ?TaxonInterface; |
75 | 135 | |
136 | + /** |
|
137 | + * @return void |
|
138 | + */ |
|
76 | 139 | public function setMenuTaxon(?TaxonInterface $menuTaxon): void; |
77 | 140 | |
78 | 141 | /** |
@@ -82,8 +145,14 @@ discard block |
||
82 | 145 | */ |
83 | 146 | public function getCountries(): Collection; |
84 | 147 | |
148 | + /** |
|
149 | + * @return void |
|
150 | + */ |
|
85 | 151 | public function addCountry(CountryInterface $country): void; |
86 | 152 | |
153 | + /** |
|
154 | + * @return void |
|
155 | + */ |
|
87 | 156 | public function removeCountry(CountryInterface $country): void; |
88 | 157 | |
89 | 158 | public function hasCountry(CountryInterface $country): bool; |
@@ -20,5 +20,9 @@ |
||
20 | 20 | { |
21 | 21 | public function findOneByIdAndCartId($id, $cartId): ?OrderItemInterface; |
22 | 22 | |
23 | + /** |
|
24 | + * @param string $id |
|
25 | + * @param string|null $tokenValue |
|
26 | + */ |
|
23 | 27 | public function findOneByIdAndCartTokenValue($id, $tokenValue): ?OrderItemInterface; |
24 | 28 | } |
@@ -17,9 +17,15 @@ |
||
17 | 17 | |
18 | 18 | interface ConfigurableShippingMethodElementInterface extends ResourceInterface |
19 | 19 | { |
20 | + /** |
|
21 | + * @return string |
|
22 | + */ |
|
20 | 23 | public function getType(): ?string; |
21 | 24 | |
22 | 25 | public function getConfiguration(): array; |
23 | 26 | |
27 | + /** |
|
28 | + * @return ShippingMethodInterface |
|
29 | + */ |
|
24 | 30 | public function getShippingMethod(): ?ShippingMethodInterface; |
25 | 31 | } |
@@ -38,18 +38,38 @@ discard block |
||
38 | 38 | |
39 | 39 | public function getName(): ?string; |
40 | 40 | |
41 | + /** |
|
42 | + * @return void |
|
43 | + */ |
|
41 | 44 | public function setName(?string $name): void; |
42 | 45 | |
43 | 46 | public function getDescription(): ?string; |
44 | 47 | |
48 | + /** |
|
49 | + * @return void |
|
50 | + */ |
|
45 | 51 | public function setDescription(?string $description): void; |
46 | 52 | |
53 | + /** |
|
54 | + * @return integer |
|
55 | + */ |
|
47 | 56 | public function getPosition(): ?int; |
48 | 57 | |
58 | + /** |
|
59 | + * @param integer $position |
|
60 | + * |
|
61 | + * @return void |
|
62 | + */ |
|
49 | 63 | public function setPosition(?int $position): void; |
50 | 64 | |
65 | + /** |
|
66 | + * @return ShippingCategoryInterface |
|
67 | + */ |
|
51 | 68 | public function getCategory(): ?ShippingCategoryInterface; |
52 | 69 | |
70 | + /** |
|
71 | + * @return void |
|
72 | + */ |
|
53 | 73 | public function setCategory(?ShippingCategoryInterface $category); |
54 | 74 | |
55 | 75 | /** |
@@ -59,9 +79,13 @@ discard block |
||
59 | 79 | * 1) None of shippables matches the category. |
60 | 80 | * 2) At least one of shippables matches the category. |
61 | 81 | * 3) All shippables have to match the method category. |
82 | + * @return integer |
|
62 | 83 | */ |
63 | 84 | public function getCategoryRequirement(): ?int; |
64 | 85 | |
86 | + /** |
|
87 | + * @return void |
|
88 | + */ |
|
65 | 89 | public function setCategoryRequirement(?int $categoryRequirement): void; |
66 | 90 | |
67 | 91 | /** |
@@ -71,11 +95,15 @@ discard block |
||
71 | 95 | |
72 | 96 | /** |
73 | 97 | * @param string $calculator |
98 | + * @return void |
|
74 | 99 | */ |
75 | 100 | public function setCalculator(?string $calculator): void; |
76 | 101 | |
77 | 102 | public function getConfiguration(): array; |
78 | 103 | |
104 | + /** |
|
105 | + * @return void |
|
106 | + */ |
|
79 | 107 | public function setConfiguration(array $configuration): void; |
80 | 108 | |
81 | 109 | /** |
@@ -89,11 +117,18 @@ discard block |
||
89 | 117 | |
90 | 118 | public function hasRule(ShippingMethodRuleInterface $rule): bool; |
91 | 119 | |
120 | + /** |
|
121 | + * @return void |
|
122 | + */ |
|
92 | 123 | public function addRule(ShippingMethodRuleInterface $rule): void; |
93 | 124 | |
125 | + /** |
|
126 | + * @return void |
|
127 | + */ |
|
94 | 128 | public function removeRule(ShippingMethodRuleInterface $rule): void; |
95 | 129 | |
96 | 130 | /** |
131 | + * @param string $locale |
|
97 | 132 | * @return ShippingMethodTranslationInterface |
98 | 133 | */ |
99 | 134 | public function getTranslation(?string $locale = null): TranslationInterface; |
@@ -17,9 +17,22 @@ |
||
17 | 17 | |
18 | 18 | interface ShippingMethodRuleInterface extends ResourceInterface, ConfigurableShippingMethodElementInterface |
19 | 19 | { |
20 | + /** |
|
21 | + * @param string $type |
|
22 | + * |
|
23 | + * @return void |
|
24 | + */ |
|
20 | 25 | public function setType(?string $type): void; |
21 | 26 | |
27 | + /** |
|
28 | + * @return void |
|
29 | + */ |
|
22 | 30 | public function setConfiguration(array $configuration): void; |
23 | 31 | |
32 | + /** |
|
33 | + * @param ShippingMethod|null $shippingMethod |
|
34 | + * |
|
35 | + * @return void |
|
36 | + */ |
|
24 | 37 | public function setShippingMethod(?ShippingMethodInterface $shippingMethod): void; |
25 | 38 | } |