Im using an on change function in a drop down user input. I have 4 choice values to determine price 0,100,500,1000. I am currently using greater or equal (ge) so they just display all the data in the price field above the choice that is chosen from the dropdown. However I want to be able to filter with a limit e.g. 0-100, 100-500, 500-1000, and above 1000. but i’m not sure on the code to use. i am using ge condition but i dont know what condition i would use to make the choices limited like 0-100? how would i set the between values? would i write a line of code for each between choice
this is my code so far (pretty basic i know):
export function pricedropdown_change(event, $w) {
$w(‘#dataset1’). setFilter(wixData.filter().ge(“costAmount”, parseFloat($w(‘#pricedropdown’).value)))
. **catch** ((error) => {
let errorMsg = error.message;
let code = error.code;
});
}