Hi I have this code: import {wixData} from 'wix-data'; export function button2_click_1 (event, $ w) { $ w ("# dataset1"). setFilter (wixData.filter () .contains ("propType", $ w ('# dropdown1'). value) .ge ("bedrooms", $ w ('# dropdown2'). value) .ge ("bathrooms", $ w ('# dropdown3'). value) .ge ("pool", $ w ('# dropdown6'). value) .ge ("safetyApartments", $ w ('# dropdown7'). value) .ge ("accessibility", $ w ('# dropdown8'). value) .ge ("location", $ w ('# dropdown9'). value) .ge ("pets", $ w ('# dropdown10'). value) .between ("priceMth", parseFloat ($ w ('# dropdown4'). value), parseFloat ($ w ('# dropdown5'). value))) .then ((results) => { console.log ("Dataset is now filtered"); $ w ("# repeater1"). data = results.items; }). catch ((err) => { console.log (err); }); $ w ("# repeater1"). expand (); } I need help to know how to implement a "or" / "and" function that allows visitors to select only one dropdown and display the search result, but if you select multiple dropdowns, it also shows the result. For example, if you select only the dropdown Pool = Yes, that shows the result of all the properties with pool But if you also want to filter pool and location, you can do it. Thank you,
top of page
Important forum update
This forum is migrating to one unified Wix community forum starting July 26th, and will be read-only during the process.
Wishlist Page is the official platform for requesting new features. You can vote, comment, and track the status of the requested features.
bottom of page
There are a good few examples already in this forum that you can view which should help with this.
https://www.wix.com/corvid/forum/community-discussion/filtering-repeater-with-a-dropdown
https://www.wix.com/corvid/forum/community-discussion/repeater-drop-down-filter