fix: #3628164 Podcast views repeat episodes and inflate counts on multilingual sites
Issue: https://www.drupal.org/project/varbase_podcasts_base/issues/3628164
Two changes in config/:
views.view.podcast_episodes.yml, displaymore_by_podcast: stop inheriting the default filters and query (defaults.filters: false,defaults.query: false) and set its own: the three default filters (type, langcode, status), a langcode filter on thefield_podcastrelationship and one onreverse__node__field_podcast(interface language,und,zxx), and a distinct query.views.view.podcasts.yml: the Episodes count on thereverse__node__field_podcastrelationship aggregates ascount_distinctinstead ofcount.
Why: both relationships join every translation of the related node, and only the base table was filtered by language, so the rail repeated an episode and the cards counted each episode once per translation (19 episodes read as 76).
Verified by applying the same configuration through config actions on a fresh Rightup 1.0 build with an Arabic translation, in English and Arabic: the block showed three different episodes (before: the same episode twice) and the cards read 19, 10 and 8 episodes (before: 76 and 40 were observed). The YAML in this MR was parsed but not applied from the MR branch, and no recipe install or Behat run was done with it.
GitLab CI: the merge request pipeline finished green. Not verified: a monolingual site (should be unchanged, since every row is in one language) and the other displays of these views.
AI-Generated: Yes
Checkpoints:
- File an issue
- Addition/Change/Update/Fix
- Testing to ensure no regression
- Automated unit testing coverage
- Automated functional testing coverage
- UX/UI designer responsibilities
- Readability
- Accessibility
- Performance
- Security
- Developer Documentation
- User Guide Documentation
- Reviewed by human
- Code review by maintainers
- Full testing and approval
- Credit contributors
- Review with the product owner
- Release notes snippet
- Release