Dear All, I just need and help to fix a code in a dynamic page collection.
In this page of a Real Estate company, https://www.homepluscasa.com/listaimmobili
we need to add another filter, “TIPOLOGIA” that shall work with : .contains, 'cause it is a text
but I guess I did something wrong 'cause it is not working.
Please find the following code :
import {wixData} from ‘wix-data’;
export function button24_click_1(event, $w) {
$w("#dynamicDataset").setFilter(wixData.filter()
.contains(("citta", $w('#dropdown1').value)
.contains("tipologia", $w('#dropdown5').value)
.between("prezzo",parseFloat($w('#dropdown2').value), parseFloat($w('#dropdown4').value)))
.then((results)=> {
console.log("Dataset is now filtered");
$w("#repeater2").data = results.items;
}).catch((err)=> {
console.log(err);
});
$w("#repeater2").expand();
}
Here you could find the code with the string contain the TIPOLOGIA filter as well,
but in the on line page I just removed to make the page working correctly for now.
All the other string work correctly
Any suggestions ?