forked from UKSOURCE/cms.hailearning.edu.vn
feat: standardize admin form limits and guidance
This commit is contained in:
@@ -11,70 +11,70 @@ if (mongoose.connection.models.Booking) {
|
||||
const bookingSchema = new mongoose.Schema(
|
||||
{
|
||||
hero: {
|
||||
title: String,
|
||||
backgroundImage: String,
|
||||
title: { type: String, trim: true, maxlength: 80 },
|
||||
backgroundImage: { type: String, trim: true, maxlength: 255 },
|
||||
},
|
||||
|
||||
searchBar: {
|
||||
locationLabel: String,
|
||||
holidaySeasonLabel: String,
|
||||
searchButtonText: String,
|
||||
locationLabel: { type: String, trim: true, maxlength: 64 },
|
||||
holidaySeasonLabel: { type: String, trim: true, maxlength: 64 },
|
||||
searchButtonText: { type: String, trim: true, maxlength: 64 },
|
||||
},
|
||||
|
||||
filterPanel: {
|
||||
title: String,
|
||||
priceTitle: String,
|
||||
priceLabel: String,
|
||||
pricePlaceholder: String,
|
||||
title: { type: String, trim: true, maxlength: 80 },
|
||||
priceTitle: { type: String, trim: true, maxlength: 64 },
|
||||
priceLabel: { type: String, trim: true, maxlength: 64 },
|
||||
pricePlaceholder: { type: String, trim: true, maxlength: 64 },
|
||||
priceMin: Number,
|
||||
priceMax: Number,
|
||||
activitiesTitle: String,
|
||||
ageTitle: String,
|
||||
ageSelectPlaceholder: String,
|
||||
activitiesTitle: { type: String, trim: true, maxlength: 64 },
|
||||
ageTitle: { type: String, trim: true, maxlength: 64 },
|
||||
ageSelectPlaceholder: { type: String, trim: true, maxlength: 64 },
|
||||
ageMin: Number,
|
||||
ageMax: Number,
|
||||
ratingTitle: String,
|
||||
ratingTitle: { type: String, trim: true, maxlength: 64 },
|
||||
ratingOptions: [
|
||||
{
|
||||
value: String,
|
||||
label: String,
|
||||
value: { type: String, trim: true, maxlength: 48 },
|
||||
label: { type: String, trim: true, maxlength: 64 },
|
||||
},
|
||||
],
|
||||
resetButtonText: String,
|
||||
resetButtonText: { type: String, trim: true, maxlength: 64 },
|
||||
},
|
||||
|
||||
programs: [
|
||||
{
|
||||
value: String,
|
||||
label: String,
|
||||
value: { type: String, trim: true, maxlength: 64 },
|
||||
label: { type: String, trim: true, maxlength: 64 },
|
||||
},
|
||||
],
|
||||
|
||||
holidays: [
|
||||
{
|
||||
value: String,
|
||||
label: String,
|
||||
value: { type: String, trim: true, maxlength: 64 },
|
||||
label: { type: String, trim: true, maxlength: 64 },
|
||||
},
|
||||
],
|
||||
|
||||
locations: [
|
||||
{
|
||||
value: String,
|
||||
label: String,
|
||||
value: { type: String, trim: true, maxlength: 64 },
|
||||
label: { type: String, trim: true, maxlength: 64 },
|
||||
},
|
||||
],
|
||||
|
||||
camps: [
|
||||
{
|
||||
name: String,
|
||||
name: { type: String, trim: true, maxlength: 120 },
|
||||
price: Number,
|
||||
priceText: String,
|
||||
priceText: { type: String, trim: true, maxlength: 32 },
|
||||
season: [String],
|
||||
age: [Number],
|
||||
locations: [String],
|
||||
image: String,
|
||||
link: String,
|
||||
program: String,
|
||||
image: { type: String, trim: true, maxlength: 255 },
|
||||
link: { type: String, trim: true, maxlength: 255 },
|
||||
program: { type: String, trim: true, maxlength: 80 },
|
||||
rating: Number,
|
||||
},
|
||||
],
|
||||
@@ -103,4 +103,4 @@ const bookingSchema = new mongoose.Schema(
|
||||
}
|
||||
);
|
||||
|
||||
module.exports = mongoose.model("Booking", bookingSchema);
|
||||
module.exports = mongoose.model("Booking", bookingSchema);
|
||||
|
||||
Reference in New Issue
Block a user