- Iscrizione Conacreis

- Ordini
- Carrello
This commit is contained in:
Paolo Arena
2021-04-30 01:31:12 +02:00
parent 0b4203067a
commit e05bbb39ee
41 changed files with 1495 additions and 337 deletions

View File

@@ -56,9 +56,45 @@ const MyPageSchema = new Schema({
imgback: {
type: String,
},
img1: {
type: String,
},
content: {
type: String,
},
video1: {
type: String,
},
ratio1: {
type: String,
},
img2: {
type: String,
},
content2: {
type: String,
},
video2: {
type: String,
},
ratio2: {
type: String,
},
img3: {
type: String,
},
content3: {
type: String,
},
video3: {
type: String,
},
ratio3: {
type: String,
},
content4: {
type: String,
},
active: {
type: Boolean,
},
@@ -101,6 +137,28 @@ MyPageSchema.statics.findAllIdApp = async function (idapp) {
});
};
MyPageSchema.statics.findOnlyStruttRec = async function (idapp) {
const MyPage = this;
const myfind = { idapp };
return MyPage.find(myfind, {
title: 1,
icon: 1,
order: 1,
keywords: 1,
description: 1,
path: 1,
active: 1,
onlyif_logged: 1,
only_residenti: 1,
inmenu: 1,
submenu: 1
}, (err, arrrec) => {
return arrrec
});
};
const MyPage = mongoose.model('MyPage', MyPageSchema);
module.exports = { MyPage };