Hi,
Problem
Actually, I created a webform on a multilingue project which contains a component using Term select.
This component is linked to a vocabulary, some of terms are translated.
When i printed my webform, I saw that in list terms options, terms name are printed in the original language but not with the current language of the page.
Proposed resolution
Before the term name is get:
- Check if the term is translatable and has a translation to get it
- Use the name of the translatable term instead of the original name.
Please see the attached patch in my next comment.
Comments
Comment #2
tsymi commentedComment #4
tsymi commentedSorry, please find my patch fixed.
Comment #6
tsymi commentedPatch attached with another fix.
Comment #7
jrockowitz commentedThe only tweak that I am going to make is change...
...to...
...because as general rule, it is okay to let the source language bleed through when there is no translation. If a vocabulary had no translated terms the menu would be empty or if a parent term is missing a translation, the menu would appear broken.
Comment #8
jrockowitz commentedComment #10
jrockowitz commented@Tsymi thanks for the patch.
I committed the latest patch. Please download and review the latest dev release. Don't hesitate to post more tweaks and reopen this ticket if needed.
Comment #11
tsymi commentedHi jrockowitz,
Thanks for your return :)