- aggiunto componenti per Home Template... ma ancora da provare

- sistemato catprods
- Sistemato menu
This commit is contained in:
Surya Paolo
2025-09-22 19:09:02 +02:00
parent 4a05ddee50
commit 08cf4b6d9f
31 changed files with 475 additions and 31 deletions

View File

@@ -121,7 +121,7 @@ CatProdSchema.statics.getCatProdWithTitleCount = async function (idapp, updateda
input: "$products",
as: "prod",
cond: {
$in: ["$$prod.idStatoProdotto", [1, 4, 34, 45, 46]]
$in: ["$$prod.productInfo.idStatoProdotto", [1, 4, 34, 45, 46]]
}
}
}
@@ -152,6 +152,8 @@ CatProdSchema.statics.getCatProdWithTitleCount = async function (idapp, updateda
const result = await CatProd.aggregate(myquery);
// console.log(JSON.stringify(myquery, null, 2))
if (updatedata) {
for (const record of result) {
await CatProd.updateOne(