/** * Created by Mai on 2017/7/25. * 量价 */ let mongoose = require("mongoose"); let Schema = mongoose.Schema; let deleteSchema = require('../../../public/models/delete_schema'); let subSchema = require('../../main/models/bills_sub_schemas'); let collectionName = 'volume_price'; let volumePriceSchema = new Schema({ // id ID: Number, // 关联pm projectID: Number, // 关联 Bills billsItemID: Number, // 排序 serialNo: Number, // 编号 code: String, // 量价类型:人工、材料、机械、主材、设备 type: String, programID: Number, // 名称 name: String, // 单位 unit: String, // 数量 quantity: Number, marketUnitFee: String, marketTotalFee: String, // 费用字段 fees: [subSchema.feesSchema], // 是否删除 deleteInfo: deleteSchema }); module.exports = mongoose.model(collectionName, volumePriceSchema);