0

I need a view to display results based on the following:

  • if the content has a translation available in the language of the current page, show that one
  • if the content DOES NOT have a translation available in the language of the current page, then show the original source of the content

The same content item can be shown only once, regardless of language (i.e. if the content is shown in english then it cannot also be shown in spanish in the same view).

Thanks for the help.

EDIT: Additional information.

Most* content is sourced in English and some of it is translated to Spanish. There are three pieces of content, however, who's original language is Spanish and do not have an English translation.

So, when viewing the aggregation page in Spanish, I should see the three Spanish articles as well as all of the other English articles, but I should see the English articles who have a translation in Spanish have their Spanish translations rendered. I should also see all of the English articles who don't have Spanish translations.

When viewing in English, I should see all of the articles in English with the exception of the three Spanish articles who should be rendered in Spanish (since it's the only available language for those articles).

EDIT: Image showing configuration of the view currently.

enter image description here

EDIT: Image showing available filter options for Original language.

enter image description here

  • 1
    see the second option in this comment drupal.stackexchange.com/questions/261401/… – 4k4 Nov 21 '18 at 7:22
  • I'm missing this filter option: Translation language (= Content language selected for page). The only one I see is Translation language (= Interface text language selected for page). – Lester Peabody Nov 21 '18 at 15:28
  • Both are the same unless Customize Content language detection to differ from Interface text language detection settings is enabled in language configuration. – 4k4 Nov 21 '18 at 16:05
  • Hm okay. That is not enabled for our site so that shouldn't be affecting things. I'll post a picture of my view configuration, as I followed the steps in that linked issue and I'm still not seeing all entities showing in the expected translation. Still just seeing the three Spanish articles when viewing the page in Spanish instead of all of the articles showing English and also those three Spanish articles showing Spanish.... – Lester Peabody Nov 21 '18 at 16:21
  • For the second option you have to filter the original language. – 4k4 Nov 21 '18 at 16:32

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.