1234567891011121314151617181920212223242526272829303132 |
- /**
- * 定额库数据模型
- *
- * @author CaiAoLin
- * @date 2017/8/1
- * @version
- */
- import mongoose from "mongoose";
- let Schema = mongoose.Schema;
- let collectionName = 'std_ration_lib_map';
- let modelSchema = {
- // 自增id
- ID: {
- type: Number,
- index: true
- },
- // 展示名称
- dispName: String,
- // app类型
- appType: Number,
- // 编办id
- compilationId: {
- type: String,
- index: true
- },
- descr: String,
- // 是否被删除
- deleted: Boolean
- };
- let model = mongoose.model(collectionName, new Schema(modelSchema, {versionKey: false, collection: collectionName}));
- export {model as default, collectionName as collectionName};
|