|
@@ -3,7 +3,10 @@ const Schema = require('mongoose').Schema;
|
|
|
const metaPlugin = require('naf-framework-mongoose/lib/model/meta-plugin');
|
|
|
// 测试信息
|
|
|
const TestmessSchema = {
|
|
|
- title: { type: String, required: true, maxLength: 200 }, // 标题
|
|
|
+ title: { type: String, required: false, maxLength: 200 }, // 标题
|
|
|
+ publish_time: { type: String, required: false, maxLength: 200 }, // 发布时间
|
|
|
+ origin: { type: String, required: false, maxLength: 200 }, // 来源
|
|
|
+ content: { type: String, required: false, maxLength: 200 }, // 内容
|
|
|
};
|
|
|
|
|
|
const schema = new Schema(TestmessSchema, { toJSON: { virtuals: true } });
|