hi, Tiaan…i appreciate your taking the time out to assist…that video, in particular, seemed geared toward a problem different from that i was having…however, one you posted later does, in part, address my initial concern…it’s the one regarding using wix data filters…i’ve studied and attempted to implement the code, but still have yet to achieve success…i was hoping you’d be able to assist…here’s what i have so far:
// For full API documentation, including code examples, visit Velo API Reference - Wix.com
import wixData from ‘wix-data’;
export function button1_click(event, $w) {
$w(‘#dataset1’).setFilter(wixData.filter()
.contains(“instruments”, $w(‘#sInstrument’).value)
.contains(“classification”, $w(‘#dropdown1’).value)
.contains(“city”, $w(‘#dropdown2’).value)
.contains(“state”, $w(‘#dropdown3’).value)
.contains(“school”, $w(‘#dropdown4’).value))
.then((res) => {
// Set the table data to be the results of the query
$w('#table1').rows = res.items;
})
$w(‘#table1’).show();
}
$w.onReady( function () {
//TODO: write your page related code here…
$w(“#table1”).columns = [
{
“id”: “col1”, // ID of the column for code purposes
// The field key in the collection whose data this column displays
“dataPath”: “firstName”,
“label”: “First Name”, // The column header
“width”: 100, // Column width
“visible”: true , // Column visibility
“type”: “string”, // Data type for the column
// Path for the column if it contains a link
“linkPath”: “link-field-or-property”
},
{
“id”: “col2”,
“dataPath”: “lastName”,
“label”: “Last Name”,
“width”: 100,
“visible”: true ,
“type”: “string”,
“linkPath”: “link-field-or-property”
},
{
“id”: “col3”,
“dataPath”: “classification”,
“label”: “Classification”,
“width”: 100,
“visible”: true ,
“type”: “string”,
“linkPath”: “link-field-or-property”
},
{
“id”: “col4”,
“dataPath”: “city”,
“label”: “State”,
“width”: 100,
“visible”: true ,
“type”: “string”,
“linkPath”: “link-field-or-property”
},
{
“id”: “col5”,
“dataPath”: “state”,
“label”: “State”,
“width”: 100,
“visible”: true ,
“type”: “string”,
“linkPath”: “link-field-or-property”
},
{
“id”: “col6”,
“dataPath”: “video”,
“label”: “Video”,
“width”: 100,
“visible”: true ,
“type”: “video”,
“linkPath”: “link-field-or-property”
}
]
});
very, very briefly, i’ll see a flash of data in the table and then it goes blank…further, aft4er having chosen a parameter in one dropdown and clicking the search button, all other dropdowns become inoperative…i don’t seem to be able to filter on multiple parameters, or to choose new options for further searches…can you give me an idea of what i’m doing wrong?