compleRation_coe.js 1013 B

1234567891011121314151617181920212223242526272829303132333435363738
  1. 'use strict';
  2. /**
  3. *
  4. *
  5. * @author Zhong
  6. * @date 2018/10/23
  7. * @version
  8. */
  9. /*
  10. * 补充定额库用户新增子目换算
  11. * 用户ID与费用定额ID绑定子目换算
  12. * */
  13. // import mongoose from 'mongoose';
  14. let mongoose = require("mongoose");
  15. const Schema = mongoose.Schema;
  16. const coeSchema = new Schema({
  17. coeType: String, // 系数类型
  18. gljCode: String, //要调整的人材机编码
  19. gljName: String,
  20. operator: String, // 运算符(*、+、-、=)
  21. amount: String, // 调整的量
  22. _id: false
  23. });
  24. const coeListSchema = new Schema({
  25. userId: String,
  26. compilationId: String,
  27. ID: String, // uuid
  28. serialNo: Number, //编号
  29. name: String, // 名称
  30. content: String, // 说明
  31. coes: [coeSchema]
  32. }, {versionKey: false});
  33. mongoose.model('complementary_ration_coe_list', coeListSchema, 'complementary_ration_coe_list');