I am seeing some strange i18n-related behaviour of DS token fields. I have a content type (building) containing a field collection (list of contributors with their roles, both references to content and taxonomy respectively). I created two simple DS token fields to display two or three separate fields as one nice string:
[node:field_address:value], [node:field_city], [node:field_artefact_country] for the building and
[field_collection_item:field_speciality]: [field_collection_item:field_artist] for its field collection.
For the screenshots I included into the node display both individual City and Country fields and the token field based on them just to illustrate the issue.
In English (default language) everything displays fine:
English (default)
But when I switch to Russian, all individual fields AND the token field within the field collection are rendered in Russian as you can see but the city and country names in the "Full Address" token field stay in English.
Russian
Am I missing something obvious or is it a bug?

Support from Acquia helps fund testing for Drupal Acquia logo

Comments

ndlarge created an issue. See original summary.

marassa’s picture

Issue tags: +i18n
RAWDESK’s picture

Looks like a bug to me.
Had a similar symptom on custom wrapper url tokens.
Maybe have a look at this to find a solution :
https://www.drupal.org/node/2475743#comment-11833928

mErilainen’s picture

Version: 8.x-3.x-dev » 8.x-2.6
Assigned: Unassigned » mErilainen
Category: Support request » Bug report
Priority: Normal » Major
FileSize
2.12 KB

Here is a patch against the latest stable version.

marassa’s picture

Applied the patch - doesn't work for me, sorry... Nothing's changed.

aspilicious’s picture

It would be better if someone could write a patch for this, not sure how to do it as we don't have any multilingual tests yet.

Jānis Bebrītis’s picture

Version: 8.x-2.6 » 8.x-3.1
FileSize
2.09 KB

#4 worked for us until the core and ds upgrade.
Here's a #4 reworked for DS 3.1

fcasanellas’s picture

Thanks! #7 worked for me!
Could it be included on the new release?

aspilicious’s picture

Status: Active » Fixed

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.