For some of my entity reference fields I'm using "Views: Filter by an entity reference views" as reference method. I've configured those views to use the current interface language for rendering (with fallback to default lang).

enter image description here

The interface language selection basically works (in other view blocks, or when previewing in /admin/structure/views), but it does not work when used as source for an entity reference field:

  • In my admin interface I'm using I've got a paragraph with an ER field using such a view as source. The paragraph always shows the title in default lang
  • On the frontend I've got a webform select field using the same view as source. The select options are always rendering in default lang.
  • When using the default reference method I do get translated titles in both use cases.
  • As stated above, the correct language is used in preview on /admin/structure/views

How can I select the correct language for my view-filtered ER fields?

  • Under filter criteria section, remove "Content: Default translation" and add " Content: Translation language (= Interface text language selected for page)" – lamp5 Dec 12 '18 at 15:33
  • This would disable the fallback functionality to default language if the entity is not translated into the current interface language. – Hudri Dec 12 '18 at 15:58

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.