|
@@ -10,6 +10,7 @@ const actTags = {
|
|
status: { type: String, required: false, default: '0', zh: '状态' }, // 字典:use
|
|
status: { type: String, required: false, default: '0', zh: '状态' }, // 字典:use
|
|
file: { type: Array, required: false, zh: '图片' }, //
|
|
file: { type: Array, required: false, zh: '图片' }, //
|
|
show_index: { type: String, required: false, default: '0', zh: '是否在首页展示' }, // 字典:use
|
|
show_index: { type: String, required: false, default: '0', zh: '是否在首页展示' }, // 字典:use
|
|
|
|
+ show_goods: { type: String, required: false, default: '1', zh: '是否显示商品标签' }, // 字典:use
|
|
};
|
|
};
|
|
const schema = new Schema(actTags, { toJSON: { getters: true, virtuals: true } });
|
|
const schema = new Schema(actTags, { toJSON: { getters: true, virtuals: true } });
|
|
schema.index({ id: 1 });
|
|
schema.index({ id: 1 });
|
|
@@ -17,6 +18,7 @@ schema.index({ 'meta.createdAt': 1 });
|
|
schema.index({ sort: 1 });
|
|
schema.index({ sort: 1 });
|
|
schema.index({ status: 1 });
|
|
schema.index({ status: 1 });
|
|
schema.index({ show_index: 1 });
|
|
schema.index({ show_index: 1 });
|
|
|
|
+schema.index({ show_goods: 1 });
|
|
|
|
|
|
schema.plugin(metaPlugin);
|
|
schema.plugin(metaPlugin);
|
|
|
|
|