Problem/Motivation

When tac_lite is installed, using a views filter on term with hierarchy, and that term has translation, it will be shown as duplicates. twice the options.

If "Adminster Tac Lite" permission is added to anonymous user, then the filter with work as expected, without duplication

Steps to reproduce

- Install tac_lite
- Have a vocabulary multi language and add some terms with respective term translation
- Build a view, and an expose filter with the term created above. Make sure it's a dropdown and "Show hierarchy in dropdown"
- go to the view page or block, and see that the dropbox have duplicate items (with same tid) on the terms that have translation

Proposed resolution

With "Adminster Tac Lite" permission set to the user and/or anonymous, it works fine.
But that is a big risky, because any anonymous user can disrupt the tac_lite parameters, if they find the path.

I don't know what to do in order to find this bug.

Any help will be greatly appreciated.

Thanks.

Comments

jrochate created an issue. See original summary.

lolgm’s picture

StatusFileSize
new423 bytes

The way I found to fix this error, to prevent duplication of items, I added the distict function when the query is changed by the hook "tac_lite_query_term_access_alter".

jrochate’s picture

Status: Active » Reviewed & tested by the community

Thanks.

Now it works like a charm.
For multilane sites, this is an important fix.

lolgm’s picture

Version: 8.x-1.5 » 8.x-1.6
StatusFileSize
new445 bytes

Reroll patch #2

  • vladimiraus committed 17e5e834 on 8.x-1.x
    Issue #3200468 by lolgm, jrochate: Duplicate terms on views hierarchy...
vladimiraus’s picture

Version: 8.x-1.6 » 8.x-1.x-dev
Status: Reviewed & tested by the community » Fixed

Thank you. Committed. 🎂

  • vladimiraus committed 17e5e834 on 2.0.x
    Issue #3200468 by lolgm, jrochate: Duplicate terms on views hierarchy...

Status: Fixed » Closed (fixed)

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