Skip to content

Commit ce1237a

Browse files
committed
Order constrains alphabetically by EU country code (#10)
1 parent 22ddb20 commit ce1237a

File tree

1 file changed

+45
-45
lines changed

1 file changed

+45
-45
lines changed

tests/Application/config/validator/Address.xml

Lines changed: 45 additions & 45 deletions
Original file line numberDiff line numberDiff line change
@@ -30,42 +30,36 @@
3030
</property>
3131

3232
<property name="vatNumber">
33-
<constraint name="Webgriffe\SyliusItalianInvoiceableOrderPlugin\Validator\Constraints\ItalianVatNumber">
34-
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.italian_vat_number.valid</option>
35-
<option name="groups">
36-
<value>company-IT</value>
37-
</option>
38-
</constraint>
3933
<constraint name="Symfony\Component\Validator\Constraints\NotBlank">
4034
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.italian_vat_number.not_blank</option>
4135
<option name="groups">
42-
<value>company-IT</value>
4336
<value>company-AT</value>
4437
<value>company-BE</value>
4538
<value>company-BG</value>
46-
<value>company-HR</value>
4739
<value>company-CY</value>
4840
<value>company-CZ</value>
41+
<value>company-DE</value>
4942
<value>company-DK</value>
5043
<value>company-EE</value>
44+
<value>company-GR</value><!-- EL -->
45+
<value>company-ES</value>
5146
<value>company-FI</value>
5247
<value>company-FR</value>
53-
<value>company-DE</value>
54-
<value>company-GR</value>
48+
<value>company-HR</value>
5549
<value>company-HU</value>
5650
<value>company-IE</value>
51+
<value>company-IT</value>
52+
<value>company-LU</value>
5753
<value>company-LV</value>
5854
<value>company-LT</value>
59-
<value>company-LU</value>
6055
<value>company-MT</value>
6156
<value>company-NL</value>
6257
<value>company-PL</value>
6358
<value>company-PT</value>
6459
<value>company-RO</value>
65-
<value>company-SK</value>
66-
<value>company-SI</value>
67-
<value>company-ES</value>
6860
<value>company-SE</value>
61+
<value>company-SI</value>
62+
<value>company-SK</value>
6963
</option>
7064
</constraint>
7165
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
@@ -91,23 +85,23 @@
9185
</constraint>
9286
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
9387
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.european_vat_number.valid</option>
94-
<option name="format">HR</option>
88+
<option name="format">CY</option>
9589
<option name="groups">
96-
<value>company-HR</value>
90+
<value>company-CY</value>
9791
</option>
9892
</constraint>
9993
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
10094
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.european_vat_number.valid</option>
101-
<option name="format">CY</option>
95+
<option name="format">CZ</option>
10296
<option name="groups">
103-
<value>company-CY</value>
97+
<value>company-CZ</value>
10498
</option>
10599
</constraint>
106100
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
107101
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.european_vat_number.valid</option>
108-
<option name="format">CZ</option>
102+
<option name="format">DE</option>
109103
<option name="groups">
110-
<value>company-CZ</value>
104+
<value>company-DE</value>
111105
</option>
112106
</constraint>
113107
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
@@ -126,30 +120,37 @@
126120
</constraint>
127121
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
128122
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.european_vat_number.valid</option>
129-
<option name="format">FI</option>
123+
<option name="format">EL</option>
130124
<option name="groups">
131-
<value>company-FI</value>
125+
<value>company-GR</value><!-- EL -->
132126
</option>
133127
</constraint>
134128
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
135129
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.european_vat_number.valid</option>
136-
<option name="format">FR</option>
130+
<option name="format">ES</option>
137131
<option name="groups">
138-
<value>company-FR</value>
132+
<value>company-ES</value>
139133
</option>
140134
</constraint>
141135
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
142136
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.european_vat_number.valid</option>
143-
<option name="format">DE</option>
137+
<option name="format">FI</option>
144138
<option name="groups">
145-
<value>company-DE</value>
139+
<value>company-FI</value>
146140
</option>
147141
</constraint>
148142
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
149143
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.european_vat_number.valid</option>
150-
<option name="format">EL</option>
144+
<option name="format">FR</option>
151145
<option name="groups">
152-
<value>company-GR</value>
146+
<value>company-FR</value>
147+
</option>
148+
</constraint>
149+
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
150+
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.european_vat_number.valid</option>
151+
<option name="format">HR</option>
152+
<option name="groups">
153+
<value>company-HR</value>
153154
</option>
154155
</constraint>
155156
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
@@ -166,25 +167,31 @@
166167
<value>company-IE</value>
167168
</option>
168169
</constraint>
170+
<constraint name="Webgriffe\SyliusItalianInvoiceableOrderPlugin\Validator\Constraints\ItalianVatNumber">
171+
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.italian_vat_number.valid</option>
172+
<option name="groups">
173+
<value>company-IT</value>
174+
</option>
175+
</constraint>
169176
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
170177
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.european_vat_number.valid</option>
171-
<option name="format">LV</option>
178+
<option name="format">LU</option>
172179
<option name="groups">
173-
<value>company-LV</value>
180+
<value>company-LU</value>
174181
</option>
175182
</constraint>
176183
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
177184
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.european_vat_number.valid</option>
178-
<option name="format">LT</option>
185+
<option name="format">LV</option>
179186
<option name="groups">
180-
<value>company-LT</value>
187+
<value>company-LV</value>
181188
</option>
182189
</constraint>
183190
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
184191
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.european_vat_number.valid</option>
185-
<option name="format">LU</option>
192+
<option name="format">LT</option>
186193
<option name="groups">
187-
<value>company-LU</value>
194+
<value>company-LT</value>
188195
</option>
189196
</constraint>
190197
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
@@ -224,9 +231,9 @@
224231
</constraint>
225232
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
226233
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.european_vat_number.valid</option>
227-
<option name="format">SK</option>
234+
<option name="format">SE</option>
228235
<option name="groups">
229-
<value>company-SK</value>
236+
<value>company-SE</value>
230237
</option>
231238
</constraint>
232239
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
@@ -238,16 +245,9 @@
238245
</constraint>
239246
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
240247
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.european_vat_number.valid</option>
241-
<option name="format">ES</option>
242-
<option name="groups">
243-
<value>company-ES</value>
244-
</option>
245-
</constraint>
246-
<constraint name="Sandwich\ViesBundle\Validator\Constraint\VatNumber">
247-
<option name="message">webgriffe_sylius_italian_invoiceable_order.address.european_vat_number.valid</option>
248-
<option name="format">SE</option>
248+
<option name="format">SK</option>
249249
<option name="groups">
250-
<value>company-SE</value>
250+
<value>company-SK</value>
251251
</option>
252252
</constraint>
253253
</property>

0 commit comments

Comments
 (0)