I am trying to implement a user input filter which has the ability to filter based on two different fields (title & type to enable a full filter of all fields), I have tried the code listed below while I am getting no errors and I am able to successfully filter using the first field title however when i search for an item in my next field type the screen returns no records only a blank field . If anyone can lend me any assistance I would be grateful
See code below : -
// For full API documentation, including code examples, visit Velo API Reference - Wix.com
import wixData from ‘wix-data’;
// For full API documentation, including code examples, visit Velo API Reference - Wix.com
$w.onReady( function () {
//TODO: write your page related code here…
});
export function filterButton_onClick(event) {
$w(“#dataset1”).setFilter(wixData.filter()
.contains(“title”, $w(“#filterInput”).value)
.or(wixData.filter()
.contains(“type”, $w(“#filterInput”).value)
)
)
}
export function button1_click(event, $w) {
$w(“#dataset1”).setFilter(wixData.filter(“all”));
}