Animations in the WebEditor
This commit is contained in:
@@ -125,13 +125,19 @@ const MyPageSchema = new Schema({
|
|||||||
extraclass: {
|
extraclass: {
|
||||||
type: String,
|
type: String,
|
||||||
},
|
},
|
||||||
|
loadFirst: {
|
||||||
|
type: Boolean,
|
||||||
|
},
|
||||||
|
showFooter: {
|
||||||
|
type: Boolean,
|
||||||
|
}
|
||||||
});
|
});
|
||||||
|
|
||||||
MyPageSchema.statics.getFieldsForSearch = function () {
|
MyPageSchema.statics.getFieldsForSearch = function () {
|
||||||
return [{ field: 'title', type: tools.FieldType.string },
|
return [{ field: 'title', type: tools.FieldType.string },
|
||||||
{ field: 'keywords', type: tools.FieldType.string },
|
{ field: 'keywords', type: tools.FieldType.string },
|
||||||
{ field: 'description', type: tools.FieldType.string },
|
{ field: 'description', type: tools.FieldType.string },
|
||||||
{ field: 'content', type: tools.FieldType.string }]
|
{ field: 'content', type: tools.FieldType.string }]
|
||||||
};
|
};
|
||||||
|
|
||||||
MyPageSchema.statics.executeQueryTable = function (idapp, params, user) {
|
MyPageSchema.statics.executeQueryTable = function (idapp, params, user) {
|
||||||
@@ -149,35 +155,53 @@ MyPageSchema.statics.findAllIdApp = async function (idapp) {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
|
|
||||||
MyPageSchema.statics.findOnlyStruttRec = function (idapp) {
|
MyPageSchema.statics.findOnlyStruttRec = async function (idapp) {
|
||||||
const MyPage = this;
|
const MyPage = this;
|
||||||
|
|
||||||
const myfind = { idapp };
|
const arrFirst = await MyPage.find(
|
||||||
|
{
|
||||||
|
idapp,
|
||||||
|
loadFirst: true,
|
||||||
|
},
|
||||||
|
(err, arrrec) => {
|
||||||
|
return arrrec
|
||||||
|
});
|
||||||
|
|
||||||
|
const arrfixed = await MyPage.find(
|
||||||
|
{ idapp,
|
||||||
|
$or: [
|
||||||
|
{loadFirst: {$exists: false}},
|
||||||
|
{loadFirst: {$exists: true, $eq: false}}],
|
||||||
|
}
|
||||||
|
, {
|
||||||
|
title: 1,
|
||||||
|
subtitle: 1,
|
||||||
|
icon: 1,
|
||||||
|
order: 1,
|
||||||
|
keywords: 1,
|
||||||
|
description: 1,
|
||||||
|
path: 1,
|
||||||
|
active: 1,
|
||||||
|
onlyif_logged: 1,
|
||||||
|
only_residenti: 1,
|
||||||
|
inmenu: 1,
|
||||||
|
submenu: 1,
|
||||||
|
iconsize: 1,
|
||||||
|
extraclass: 1,
|
||||||
|
loadFirst: 1,
|
||||||
|
}, (err, arrrec) => {
|
||||||
|
return arrrec
|
||||||
|
});
|
||||||
|
|
||||||
|
return [...arrFirst, ...arrfixed];
|
||||||
|
|
||||||
return MyPage.find(myfind, {
|
|
||||||
title: 1,
|
|
||||||
subtitle: 1,
|
|
||||||
icon: 1,
|
|
||||||
order: 1,
|
|
||||||
keywords: 1,
|
|
||||||
description: 1,
|
|
||||||
path: 1,
|
|
||||||
active: 1,
|
|
||||||
onlyif_logged: 1,
|
|
||||||
only_residenti: 1,
|
|
||||||
inmenu: 1,
|
|
||||||
submenu: 1,
|
|
||||||
iconsize: 1,
|
|
||||||
extraclass: 1,
|
|
||||||
}, (err, arrrec) => {
|
|
||||||
return arrrec
|
|
||||||
});
|
|
||||||
};
|
};
|
||||||
|
|
||||||
MyPageSchema.statics.findInternalPages = async function (idapp) {
|
MyPageSchema.statics.findInternalPages = async function (idapp) {
|
||||||
const MyPage = this;
|
const MyPage = this;
|
||||||
|
|
||||||
const myfind = { idapp,
|
const myfind = {
|
||||||
|
idapp,
|
||||||
internalpage: { $exists: true, $eq: true }
|
internalpage: { $exists: true, $eq: true }
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user