zhangweicheng преди 5 години
родител
ревизия
f932012a3e
променени са 4 файла, в които са добавени 17 реда и са изтрити 27 реда
  1. 5 0
      modules/all_models/project_glj.js
  2. 4 1
      modules/main/facade/common_facade.js
  3. 8 1
      modules/ration_glj/facade/ration_glj_facade.js
  4. 0 25
      package-lock.json

+ 5 - 0
modules/all_models/project_glj.js

@@ -68,6 +68,11 @@ let modelSchema = {
         type: Number,
         default: 0
     },
+    //评标材料
+    is_eval_material:{
+      type: Number,
+      default: 0
+    },
     // 调整系数ID
     adjCoe: Number,
 

+ 4 - 1
modules/main/facade/common_facade.js

@@ -78,7 +78,10 @@ function getProjectGLJNewData(tmp, projectId, ext) {
         base_price: tmp.basePrice,
         market_price: tmp.basePrice,
         is_main_material: tmp.is_main_material ? tmp.is_main_material : 1,
-        from: tmp.from ? tmp.from : "std"
+        from: tmp.from ? tmp.from : "std",
+        is_adjust_price:0,
+        is_evaluate:0,
+        is_eval_material:0
     };
     if (gljData.from == 'std' && ext && ext.priceField && (tmp.priceProperty && tmp.priceProperty[ext.priceField] != undefined && tmp.priceProperty[ext.priceField] != null)) {
         const basePrice = scMathUtil.roundTo(tmp.priceProperty[ext.priceField], -6);

+ 8 - 1
modules/ration_glj/facade/ration_glj_facade.js

@@ -675,7 +675,8 @@ function getGLJSearchInfo(ration_glj) {
         offSiteTransportLossRate:ration_glj.offSiteTransportLossRate,
         handlingLossRate:ration_glj.handlingLossRate,
         is_adjust_price:0,
-        is_main_material:1,
+        is_evaluate:0,
+        is_eval_material:0,
         from: ration_glj.from ? ration_glj.from : 'std'//std:标准工料机库, cpt:补充工料机库
     };
     let glj_type_object = glj_type_util.getStdGljTypeCacheObj();
@@ -1180,6 +1181,12 @@ async function testError() {
 }
 
 function getData(projectID, callback, isReport) {
+    function findRation(rations, ID) {
+      let ration = rations.find(function getElement(element) {
+          return element.ID == ID;
+      });
+      return ration && ration._doc;
+    };
     ration_glj.find({'projectID': projectID}, (err, datas) => {
         if (err) {
             callback(1, '', null);

+ 0 - 25
package-lock.json

@@ -5032,31 +5032,6 @@
         }
       }
     },
-    "gulp-cli": {
-      "version": "2.3.0",
-      "resolved": "https://registry.npmjs.org/gulp-cli/-/gulp-cli-2.3.0.tgz",
-      "integrity": "sha512-zzGBl5fHo0EKSXsHzjspp3y5CONegCm8ErO5Qh0UzFzk2y4tMvzLWhoDokADbarfZRL2pGpRp7yt6gfJX4ph7A==",
-      "requires": {
-        "ansi-colors": "^1.0.1",
-        "archy": "^1.0.0",
-        "array-sort": "^1.0.0",
-        "color-support": "^1.1.3",
-        "concat-stream": "^1.6.0",
-        "copy-props": "^2.0.1",
-        "fancy-log": "^1.3.2",
-        "gulplog": "^1.0.0",
-        "interpret": "^1.4.0",
-        "isobject": "^3.0.1",
-        "liftoff": "^3.1.0",
-        "matchdep": "^2.0.0",
-        "mute-stdout": "^1.0.0",
-        "pretty-hrtime": "^1.0.0",
-        "replace-homedir": "^1.0.0",
-        "semver-greatest-satisfied-range": "^1.1.0",
-        "v8flags": "^3.2.0",
-        "yargs": "^7.1.0"
-      }
-    },
     "gulp-concat": {
       "version": "2.6.1",
       "resolved": "https://registry.npmjs.org/gulp-concat/-/gulp-concat-2.6.1.tgz",