forked from UKSOURCE/cms.hailearning.edu.vn
51 lines
858 B
JavaScript
51 lines
858 B
JavaScript
const mongoose = require('mongoose');
|
|
|
|
const formSchema = new mongoose.Schema({
|
|
name: {
|
|
type: String,
|
|
required: true,
|
|
trim: true,
|
|
unique: true
|
|
},
|
|
admission: {
|
|
background_image: String,
|
|
title: String,
|
|
year: String,
|
|
description: String,
|
|
form: {
|
|
fields: [{
|
|
type: { type: String },
|
|
placeholder: String
|
|
}],
|
|
button: {
|
|
text: String,
|
|
url: String
|
|
}
|
|
}
|
|
},
|
|
apply: {
|
|
title: String,
|
|
steps: [{
|
|
title: String,
|
|
description: String
|
|
}]
|
|
},
|
|
application_form: {
|
|
title: String,
|
|
question: String,
|
|
button: {
|
|
text: String,
|
|
icon: String,
|
|
url: String
|
|
},
|
|
links: [{
|
|
text: String,
|
|
url: String
|
|
}]
|
|
},
|
|
updatedAt: Date
|
|
}, {
|
|
timestamps: true
|
|
});
|
|
|
|
module.exports = mongoose.model('Form', formSchema);
|