ver: 1.1.21:
- Lista dei Cataloghi - Gestione Cataloghi in base alla configurazione
This commit is contained in:
@@ -4,6 +4,8 @@ const Schema = mongoose.Schema;
|
||||
const tools = require('../tools/general');
|
||||
const { ObjectId } = require('mongodb');
|
||||
|
||||
const { IImg } = require('../models/myscheda');
|
||||
|
||||
mongoose.Promise = global.Promise;
|
||||
mongoose.level = "F";
|
||||
|
||||
@@ -13,22 +15,6 @@ mongoose.plugin(schema => {
|
||||
schema.options.usePushEach = true
|
||||
});
|
||||
|
||||
const Foto = {
|
||||
imagefile: {
|
||||
type: String,
|
||||
},
|
||||
alt: {
|
||||
type: String,
|
||||
},
|
||||
description: {
|
||||
type: String,
|
||||
},
|
||||
};
|
||||
|
||||
const FilesCataloghi = {
|
||||
per_web: { type: String, },
|
||||
per_stampa: { type: String, },
|
||||
};
|
||||
|
||||
const CatalogSchema = new Schema({
|
||||
idapp: {
|
||||
@@ -38,13 +24,18 @@ const CatalogSchema = new Schema({
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
versione_perstampa: {
|
||||
type: Boolean,
|
||||
default: false,
|
||||
},
|
||||
title: {
|
||||
type: String,
|
||||
},
|
||||
foto_collana: Foto,
|
||||
foto_collana: IImg,
|
||||
idCollane: [{
|
||||
type: Number,
|
||||
}],
|
||||
editore: [{ type: String }],
|
||||
descr_introduttiva: {
|
||||
type: String,
|
||||
},
|
||||
@@ -55,13 +46,20 @@ const CatalogSchema = new Schema({
|
||||
type: String,
|
||||
}],
|
||||
|
||||
img_bordata_web: Foto,
|
||||
img_bordata_stampa: Foto,
|
||||
img_intro_web: Foto,
|
||||
img_intro_stampa: Foto,
|
||||
img_bordata: IImg,
|
||||
img_intro: IImg,
|
||||
pagina_introduttiva_sfondo_nero: {
|
||||
type: Boolean,
|
||||
},
|
||||
|
||||
generati: FilesCataloghi,
|
||||
online: FilesCataloghi,
|
||||
pdf_generato: String,
|
||||
data_generato: {
|
||||
type: Date,
|
||||
},
|
||||
pdf_online: String,
|
||||
data_online: {
|
||||
type: Date,
|
||||
},
|
||||
|
||||
date_created: {
|
||||
type: Date,
|
||||
|
||||
Reference in New Issue
Block a user