title | issue |
---|---|
Validate address information in storefront |
NEXT-21003 |
- Changed method
defineFields
ofShopware\Core\Checkout\Customer\Aggregate\CustomerAddress\CustomerAddressDefinition
to update fieldzipcode
is not required - Changed property
zipcode
and methodgetZipcode
,getZipcode
ofShopware\Core\Checkout\Customer\Aggregate\CustomerAddress\CustomerAddressEntity
to update fieldzipcode
nullable - Changed method
getCreateAddressValidationDefinition
ofShopware\Core\Checkout\Customer\SalesChannel\RegisterRoute
to add validation rule forzipcode
- Changed method
getValidationDefinition
ofShopware\Core\Checkout\Customer\SalesChannel\UpsertAddressRoute
to add validation rule forzipcode
- Added Constraint class
Shopware\Core\Checkout\Customer\Validation\Constraint\CustomerZipCode
for creating zipcode constraint - Added Validator class
Shopware\Core\Checkout\Customer\Validation\Constraint\CustomerZipCodeValidator
for handling zipcode validation - Added migration
Migration1651118773UpdateZipCodeOfTableCustomerAddressToNullable
to update zipcode field in database into nullable
- Added translation for
VIOLATION::ZIP_CODE_INVALID
ofResources/snippet/de_DE/storefront.de-DE.json
&Resources/snippet/de_DE/storefront.en-GB.json
- Changed block
component_address_form_zipcode_city
ofResources/views/storefront/component/address/address-form.html.twig
to update fieldzipcode
is not required