I translated field labels through the configuration translation module UI. When I create a node and then translate it the translated version reflects translated field labels so for example fr/node/nid has all labels translated. However if I clear the cache while still being on translated page (any path with language prefix) all labels become English (default language) again. If I switch to default language and then clear cache one more time then switch to French labels are translated again.
Basically every time the cache is cleared through UI while on the page with language prefix fr/... it resets translation for previously translated configuration items. And when the cache is cleared on default language the translation is back to normal.
On the site all multilingual core modules are enabled. Translation is enabled for content types and for fields. Default language of the site is English. Nodes were created in English with French translation.
Steps to reproduce
- Install all modules in Multilingual (language, locale, config_translation, content_translation)
- Added French language (any language should do) via /admin/config/regional/language
- Enable translation for Article under Content->Article at admin/config/regional/content-language
- Create a test Article node with some Tags content via /node/add/article
- View /fr/node/1 (or whatever), the Tags label should show as Étiquettes
- Navigate to /fr/admin/config/development/performance and clear cache via the UI
- Back to /fr/node/1 and the Étiquettes label is now "Tags"
After further investigation revealed that the translations getting cached while clearing cache in a state language override isn't in place. Which causes the system to save english/default translation into language prefixed cache key. This is caused by triggering entity title call in views route subscriber. Moving title of the route to title callback fixes the problem.
Manual testing and review.
User interface changes
Data model changes
|#118||clearing_cache_via_ui-2650434-118.patch||10.25 KB||Yogesh Pawar|