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

Translation for layered navigation attribute option not working #9679

Closed
popatkaran opened this issue May 18, 2017 · 8 comments
Closed

Translation for layered navigation attribute option not working #9679

popatkaran opened this issue May 18, 2017 · 8 comments
Labels
Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development

Comments

@popatkaran
Copy link

I am using Magento CE 2.1.6 and having multilingual structure of website. When I switch the store to Arabic language all text getting translated but only attribute options in layered navigation is not translating.

Preconditions

  1. Magento CE 2.1.6
  2. php 7.0.x

Steps to reproduce

  1. Open website with default store.
  2. Switch website with store switcher or paste direct url of another store
  3. Check layered navigation

Expected result

  1. All the text should be translated to applied language to relevant store.

Actual result

  1. All other text in website getting translated properly but attribute option name is not getting translated.
  • Working well with English store.
    m216en
  • Not working with Arabic one.
    m216ar
@tsifra
Copy link

tsifra commented May 18, 2017

Hello, did you translate it in backend - store - attributes - [attr name]?
If not - please read docs. And close the issue.

@popatkaran
Copy link
Author

@tsifra yes, I have already put translated text for the same.

I have found that if I flush cache using command after switching store translation works but, If i move back to English store attribute options remains in Arabic instead of English. This happens only for Layered navigation.

@tsifra
Copy link

tsifra commented May 18, 2017

My bad. Actually i didn't understand your problem right way. And translation of attribute was "hardcoded" by me to [atttribute] - Manage labels. Because i use only one language. Have no idea how to make different attribute labels for different languages. Maybe you have to create different stores with different labels and default languages? Please check [atttribute] - Properties tab. There are Admin and store columns for each attr value.

@popatkaran
Copy link
Author

Yes, I have multiple store which having different language as default. Store change and other front-end area are translating well but only layered navigation is causing an issue.

@hostep
Copy link
Contributor

hostep commented May 19, 2017

We ran into the same problem today after upgrading from Magento 2.1.5 to 2.1.6.
This is a new bug introduced in 2.1.6 by this commit: 67b5ff7

It's because the wrong storeId is being used in the cacheKey, because the storeResolver->getCurrentStoreId() isn't always returning the current store id.

I'm currently working on a PR which will fix this.

@okorshenko
Copy link
Contributor

The fix was delivered to 2.1-develop and develop branch. Thank you @hostep for your contribution!

@magento-team magento-team added 2.1.x Issue: Ready for Work Gate 4. Acknowledged. Issue is added to backlog and ready for development labels Jul 31, 2017
@magento-team
Copy link
Contributor

Internal ticket to track issue progress: MAGETWO-69543

@magento-team
Copy link
Contributor

Internal ticket to track issue progress: MAGETWO-69728

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
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

5 participants