| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103 | 
							- /**
 
-  * Created by zhang on 2018/3/22.
 
-  */
 
- /**
 
-  * 工料机数据模型
 
-  *
 
-  * @author CaiAoLin
 
-  * @date 2017/6/29
 
-  * @version
 
-  */
 
- import mongoose from "mongoose";
 
- let Schema = mongoose.Schema;
 
- let collectionName = 'glj_list';
 
- let modelSchema = {
 
-     // 自增id
 
-     id: Number,
 
-     // 工料机总库ID
 
-     glj_id: Number,
 
-     // 标段ID
 
-     project_id: Number,
 
-     // 编码
 
-     code: {
 
-         type: String,
 
-         index: true
 
-     },
 
-     //原始的编码
 
-     original_code: {
 
-         type: String,
 
-         index: true
 
-     },
 
-     // 名称
 
-     name: {
 
-         type: String,
 
-         index: true,
 
-         default: ''
 
-     },
 
-     // 是否暂估 (0为否 1为是)
 
-     is_evaluate: {
 
-         type: Number,
 
-         default: 0
 
-     },
 
-     // 供货方式
 
-     supply: {
 
-         type: Number,
 
-         default: 0
 
-     },
 
-     // 甲供数量
 
-     supply_quantity: {
 
-         type: Number,
 
-         default: 0
 
-     },
 
-     // 交货方式
 
-     delivery: {
 
-         type: String,
 
-         default: ''
 
-     },
 
-     // 送达地点
 
-     delivery_address: {
 
-         type: String,
 
-         default: ''
 
-     },
 
-     // 不调价
 
-     is_adjust_price: {
 
-         type: Number,
 
-         default: 0
 
-     },
 
-     // 调整系数ID
 
-     adjCoe: Number,
 
-     // 规格型号
 
-     specs: {
 
-         type: String,
 
-         default: ''
 
-     },
 
-     // 类型
 
-     type: Number,
 
-     // 单位
 
-     unit: String,
 
-     // 显示调整基价
 
-     adjust_price: String,
 
-     // 显示关联单价文件的字段
 
-     unit_price: Schema.Types.Mixed,
 
-     // 显示关联的消耗量
 
-     quantity: String,
 
-     // 显示组成物的消耗量
 
-     consumption: String,
 
-     // 显示关联配合比的id
 
-     mix_ratio_id: Number,
 
-     // 显示关联父级工料机code(组合物用)
 
-     connect_code: String,
 
-     materialType: Number,   //三材类别
 
-     materialCoe: Number,    //三材系数
 
-     // 是否主要材料 (0为否 1为是)
 
-     is_main_material: {
 
-         type: Number,
 
-         default: 0
 
-     },
 
-     ratio_data: Schema.Types.Mixed
 
- };
 
- mongoose.model(collectionName, new Schema(modelSchema, {versionKey: false}));
 
 
  |