This is the code I’m using:
I have a dropdown box for users to select a location. This is working fine. But I would like to add a filter to only show Artist from the category field that I have in my database.
At the moment the repeater is pulling all of the categories from my category filed. I don’t want to add another dropdown menu. Is there a way to add a filter or condition into the code?
Many thanks for any help on this.
import wixData from ‘wix-data’;
$w.onReady(() => {
$w(“#dataset4”).setFilter(wixData.filter().eq(‘location’,));
});
export function location_change(event) {
let myValue = $w(‘#location1’).value;
console.log(myValue,“myvalue”)
$w(“#dataset4”).setFilter(wixData.filter().eq(‘location’, myValue));