With a friend help, we create this code that results a query in array .
in console log i can see the query " arrayNotRead " results …
now big problem, is to show them in a repeater… someone know how to pass it?
many thanks.
let arrayNotRead = [] ;
wixData.query("supportRequest2")
.eq('email', userEmail)
.find()
.then((res) => {
for(let i=0; i<res.items.length;i++){
wixData.query("TicketMessage")
.eq('idesterno', res.items[i]['_id'])
.find()
.then((mess) => {
if(mess.items.length > res.items[i]['numMsgRead']){
arrayNotRead.push(res.items[i])
}
})
}
console.log(arrayNotRead);
}
)