Open mariellejl opened 9 years ago
You seem to only be filtering on $(this).val()
, which is only one value. You need to scoop up the values of all selects and feed them to filterCategories. Check out the All or nothing example on the demo page. Then, items will match if they have any or all categories depending on the requireAll option.
Hope I understood your problem. Let me know if it works. I just had a brief look at it.
Hi, I'm banging my head against a wall on an issue here, and I just cannot figure it out. I have a page with multiple dropdowns, each connected to multiple categories. What I want it to do is use these multiple dropdowns to filter a list of items. The problem is that when I choose something from the first dropdown and then from the second, the second dropdown overrides whatever I selected with the first. As I understood it from examples, it would be possible to avoid this by using requireAll: true, but I am starting to suspect that I misunderstood the functionality of it.
Is there any way of accomplishing what I want with your plugin?
I should also mention I am quite new to all of this, so I might have overlooked something completely obvious.
My js is as follows:
The select:
EDIT: With above example, with the filterCategory('') added, filtering doesn't actually work, so I'm back to