0

I'm running a music store and have a taxonomy term field on products that that is used for the product's format. We tag the products from the following vocabulary.

  • Vinyl
    • 140g vinyl
    • 180g vinyl
  • CD
    • Jewelcase
    • Digipack
  • Digital
    • Mp3
    • FLAC

I'd like create an exposed filter on the product catalog using the parent terms, Vinyl, CD, Digital. When one of taxonomy terms is selected, the filter should display all products tagged with the child terms.

The Content: Has taxonomy terms (with depth) filter doesn't seem to work with referenced products. I'm not seeing a solution in the Taxonomy Entity Index module either (but I might be wrong).

0

With a view using Products as base_table:

  1. Add a relationship using the taxonomy reference field you're using and do not require the relationship
  2. Add an exposed filter `Content: Has taxonomy terms (with depth)
  3. In the settings, set the depth to the level you want
  4. In the exposed filter itself, you can configure whether multiple values can be selected or not.

But before all that, you need to make sure that only the child terms are selected on the products.

  • Big thanks for the contribution. However it doesn't work with a View of Product Displays which is what I need. Let me know if you think of another way or a modification of your suggestion. – Kristoffer Rom Sep 17 '18 at 12:06

Your Answer

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

Not the answer you're looking for? Browse other questions tagged or ask your own question.