@russian-dima thank you, i try your code and works for the gallery but not works for finiture , i try some test and the problem probably is because Finiture is Multi-Reference field from the table Finiture.
How in can check if there is some elements inside?
if(finiture)
return always false, why? there is some way to check it there is some values inside?
console.log(finiture)
log undifined.
I tried
if(finiture.getTotalCount())
but not works.
Thank you