forked from UKSOURCE/cms.hailearning.edu.vn
feat: Improve home and contact CMS field guidance
This commit is contained in:
@@ -7,11 +7,13 @@ const heroSchema = new mongoose.Schema(
|
||||
type: String,
|
||||
required: true,
|
||||
trim: true,
|
||||
maxlength: 40,
|
||||
},
|
||||
backgroundImage: {
|
||||
type: String,
|
||||
trim: true,
|
||||
default: "",
|
||||
maxlength: 255,
|
||||
},
|
||||
overlayColor: {
|
||||
type: String,
|
||||
@@ -62,9 +64,10 @@ const contactCardSchema = new mongoose.Schema(
|
||||
type: String,
|
||||
required: true,
|
||||
trim: true,
|
||||
maxlength: 40,
|
||||
},
|
||||
content: {
|
||||
type: [String],
|
||||
type: [{ type: String, maxlength: 96 }],
|
||||
default: [],
|
||||
},
|
||||
iconType: {
|
||||
@@ -72,6 +75,7 @@ const contactCardSchema = new mongoose.Schema(
|
||||
required: false,
|
||||
trim: true,
|
||||
default: "",
|
||||
maxlength: 255,
|
||||
},
|
||||
iconSource: {
|
||||
type: String,
|
||||
@@ -139,16 +143,19 @@ const mapSchema = new mongoose.Schema(
|
||||
type: String,
|
||||
required: true,
|
||||
trim: true,
|
||||
maxlength: 120,
|
||||
},
|
||||
markerTitle: {
|
||||
type: String,
|
||||
trim: true,
|
||||
default: "",
|
||||
maxlength: 48,
|
||||
},
|
||||
embedUrl: {
|
||||
type: String,
|
||||
trim: true,
|
||||
default: "",
|
||||
maxlength: 1000,
|
||||
},
|
||||
tileLayer: {
|
||||
type: tileLayerSchema,
|
||||
@@ -165,11 +172,13 @@ const formFieldSchema = new mongoose.Schema(
|
||||
type: String,
|
||||
required: true,
|
||||
trim: true,
|
||||
maxlength: 32,
|
||||
},
|
||||
label: {
|
||||
type: String,
|
||||
trim: true,
|
||||
default: "",
|
||||
maxlength: 32,
|
||||
},
|
||||
type: {
|
||||
type: String,
|
||||
@@ -181,6 +190,7 @@ const formFieldSchema = new mongoose.Schema(
|
||||
type: String,
|
||||
trim: true,
|
||||
default: "",
|
||||
maxlength: 72,
|
||||
},
|
||||
required: {
|
||||
type: Boolean,
|
||||
@@ -195,6 +205,7 @@ const formFieldSchema = new mongoose.Schema(
|
||||
type: String,
|
||||
trim: true,
|
||||
default: "",
|
||||
maxlength: 48,
|
||||
},
|
||||
},
|
||||
{ _id: false }
|
||||
@@ -207,6 +218,7 @@ const submitButtonSchema = new mongoose.Schema(
|
||||
type: String,
|
||||
required: true,
|
||||
trim: true,
|
||||
maxlength: 24,
|
||||
},
|
||||
icon: {
|
||||
type: String,
|
||||
@@ -229,16 +241,19 @@ const formSchema = new mongoose.Schema(
|
||||
type: String,
|
||||
trim: true,
|
||||
default: "",
|
||||
maxlength: 32,
|
||||
},
|
||||
heading: {
|
||||
type: String,
|
||||
trim: true,
|
||||
default: "",
|
||||
maxlength: 48,
|
||||
},
|
||||
description: {
|
||||
type: String,
|
||||
trim: true,
|
||||
default: "",
|
||||
maxlength: 160,
|
||||
},
|
||||
fields: {
|
||||
type: [formFieldSchema],
|
||||
|
||||
Reference in New Issue
Block a user