Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Override zip_codes.xml #6694

Closed
luukschakenraad opened this issue Sep 21, 2016 · 4 comments
Closed

Override zip_codes.xml #6694

luukschakenraad opened this issue Sep 21, 2016 · 4 comments
Labels
bug report Fixed in 2.1.x The issue has been fixed in 2.1 release line Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development

Comments

@luukschakenraad
Copy link
Contributor

luukschakenraad commented Sep 21, 2016

When trying to override module-directory/etc/zip_codes.xml from a local module, only the last code of a country gets included.

Preconditions

  1. Magento 2.1.1

Steps to reproduce

  1. Follow steps as described here
  2. Add this to zip_codes.xml:

<?xml version="1.0"?> <config xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:noNamespaceSchemaLocation="urn:magento:module:Magento_Directory:etc/zip_codes.xsd"> <zip countryCode="NL"> <codes> <code id="pattern_1" active="true" example="1234 AB">^[0-9]{4}\s[a-zA-Z]{2}$</code> <code id="pattern_2" active="true" example="1234AB">^[0-9]{4}[a-zA-Z]{2}$</code> </codes> </zip> </config>

  1. Open checkout-page and enter in console: window.checkoutConfig.postCodes['NL']
  2. Only pattern 2 will be shown.
  3. Paste code from step 2 directly into the core zip_codes.xml. Redo step 3 and you will see pattern_1 and pattern_2
  4. Even when entering 5 patterns in my module's zip_codes.xml file, only the last one is shown. Pasting them in the core zip_codes.xml it works as expected.

Expected result

  1. All patterns should be included on the check-out page.

Actual result

  1. Only the last pattern from Module's zip_codes.xml is shown
@sevos1984
Copy link
Contributor

Internal ticket created MAGETWO-59258. Thanks for reporting.

@sevos1984 sevos1984 added the Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development label Oct 3, 2016
mmansoor-magento pushed a commit that referenced this issue Oct 26, 2016
…nly the last code of a country gets included #6694
mmansoor-magento pushed a commit that referenced this issue Oct 26, 2016
…nly the last code of a country gets included #6694
mmansoor-magento pushed a commit that referenced this issue Oct 26, 2016
…nly the last code of a country gets included #6694
mmansoor-magento pushed a commit that referenced this issue Oct 26, 2016
[Folks] Bugs:
- MAGETWO-59258 [Github] Override module-directory/etc/zip_codes.xml only the last code of a country gets included #6694
- MAGETWO-59512 [GitHub] Products in wishlist show $0.00 price #6866
- MAGETWO-59185 [GITHUB] Offline carrier configuration option "showmethod" does not appear in admin panel carrier configuration page #5693
- MAGETWO-59130 [Github] REST API with searchCriteria does not return category_ids #6127
- MAGETWO-57850 Unable to filter blocks using store view and block ID
- MAGETWO-57682 [GitHub] Checkout Agreement validation is broken on payment method change #6224
- MAGETWO-59573 Braintree JS error on checkout after applying 100% discount coupon with free shipping enabled
@SerhiyShkolyarenko
Copy link
Contributor

The fix is delivered to develop branch. Closing the issue.

@Ctucker9233
Copy link

@SerhiyShkolyarenko Will Magetwo-59258 be included in 2.1.3?

@magento-engcom-team
Copy link
Contributor

Hi @luukschakenraad. Thank you for your report.
The issue has been fixed in #14117 by @simpleadm in 2.1-develop branch
Related commit(s):

The fix will be available with the upcoming 2.1.14 release.

@magento-engcom-team magento-engcom-team added Fixed in 2.1.x The issue has been fixed in 2.1 release line Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed labels Mar 16, 2018
mmansoor-magento pushed a commit that referenced this issue May 11, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug report Fixed in 2.1.x The issue has been fixed in 2.1 release line Issue: Format is valid Gate 1 Passed. Automatic verification of issue format passed Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development
Projects
None yet
Development

No branches or pull requests

6 participants