Hey guys, I have a repeater which shows different projects from a collection. In the collection I have a checkbox for ‘kampage’. If this checkbox is checked, I want the #box108 to be visible else not. I have the following code but it only checks the first Item. What do I need to change to have the checkbox for every element checked?
wixData.query("Portfolio")
.find()
.then((results) => {
$w("#box108").show();
let boolean = results.items[0].kampagne;
if (boolean === true) {
$w("#box108").show();
console.log("approved");
} else {
$w("#box108").hide();
console.log("not approved");
}
})
.catch((err) => {
let errorMsg = err;
});