Browse Source

1.甲供基数调价
2.项目管理界面,“批量替换单价文件”和“批量替换费率文件”的工程列表列显示不全
3.专业版viplogo、去掉底色

vian 5 years ago
parent
commit
b911a1db6d

File diff suppressed because it is too large
+ 415 - 415
web/building_saas/css/main.css


BIN
web/building_saas/img/vip.png


+ 37 - 33
web/building_saas/main/js/models/calc_base.js

@@ -566,7 +566,7 @@ let baseFigureTemplate = {
                 //调整价
                 //调整价
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 //价差
                 //价差
-                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : glj.unit_price.market_price;
+                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
@@ -582,7 +582,7 @@ let baseFigureTemplate = {
                 //调整价
                 //调整价
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 //价差
                 //价差
-                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : glj.unit_price.market_price;
+                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
@@ -598,7 +598,7 @@ let baseFigureTemplate = {
                 //调整价
                 //调整价
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 //价差
                 //价差
-                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : glj.unit_price.market_price;
+                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
@@ -617,7 +617,7 @@ let baseFigureTemplate = {
                 //调整价
                 //调整价
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 //价差
                 //价差
-                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : glj.unit_price.market_price;
+                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
@@ -633,7 +633,7 @@ let baseFigureTemplate = {
                 //调整价
                 //调整价
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 //价差
                 //价差
-                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : glj.unit_price.market_price;
+                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
@@ -649,7 +649,7 @@ let baseFigureTemplate = {
                 //调整价
                 //调整价
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 //价差
                 //价差
-                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : glj.unit_price.market_price;
+                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
@@ -668,7 +668,7 @@ let baseFigureTemplate = {
                 //调整价
                 //调整价
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 //价差
                 //价差
-                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : glj.unit_price.market_price;
+                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
@@ -684,7 +684,7 @@ let baseFigureTemplate = {
                 //调整价
                 //调整价
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 //价差
                 //价差
-                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : glj.unit_price.market_price;
+                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
@@ -700,89 +700,93 @@ let baseFigureTemplate = {
                 //调整价
                 //调整价
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 let adjPrc = calcBase.project.projectGLJ.getAdjustPrice(glj);
                 //价差
                 //价差
-                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : glj.unit_price.market_price;
+                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 let dffPrc = parseFloat(marketPrice - adjPrc).toDecimal(decimalObj.glj.unitPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
                 rst = (rst + parseFloat(glj[quantityType] * dffPrc).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
         return rst;
         return rst;
     },
     },
-    'JGDEJJRGF': function () {//甲供定额基价人工费
+    'JGDEJJRGF': function (tender) {//甲供定额基价人工费
         let rst = 0;
         let rst = 0;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(glj.type === gljType.LABOUR){
             if(glj.type === gljType.LABOUR){
-                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj) * glj.unit_price.base_price).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
+                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj, tender) * calcBase.project.projectGLJ.getBasePrice(glj)).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
         return rst;
         return rst;
     },
     },
-    'JGDEJJCLF': function () {//甲供定额基价材料费
+    'JGDEJJCLF': function (tender) {//甲供定额基价材料费
         let rst = 0;
         let rst = 0;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(baseMaterialTypes.includes(glj.type) && glj.ratio_data.length === 0){
             if(baseMaterialTypes.includes(glj.type) && glj.ratio_data.length === 0){
-                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj) * glj.unit_price.base_price).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
+                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj, tender) * calcBase.project.projectGLJ.getBasePrice(glj)).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
         return rst;
         return rst;
     },
     },
-    'JGDEJJJXF': function () {//甲供定额基价机械费
+    'JGDEJJJXF': function (tender) {//甲供定额基价机械费
         let rst = 0;
         let rst = 0;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(baseMachineTypes.includes(glj.type) && glj.ratio_data.length === 0){
             if(baseMachineTypes.includes(glj.type) && glj.ratio_data.length === 0){
-                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj) * glj.unit_price.base_price).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
+                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj, tender) * calcBase.project.projectGLJ.getBasePrice(glj)).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
         return rst;
         return rst;
     },
     },
-    'JGRGF': function () {//甲供人工费
+    'JGRGF': function (tender) {//甲供人工费
         let rst = 0;
         let rst = 0;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(glj.type === gljType.LABOUR){
             if(glj.type === gljType.LABOUR){
-                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj) * glj.unit_price.market_price).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
+                const marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
+                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj, tender) * marketPrice).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
         return rst;
         return rst;
     },
     },
-    'JGCLF': function () {//甲供材料费
+    'JGCLF': function (tender) {//甲供材料费
         let rst = 0;
         let rst = 0;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(baseMaterialTypes.includes(glj.type) && glj.ratio_data.length === 0){
             if(baseMaterialTypes.includes(glj.type) && glj.ratio_data.length === 0){
-                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj) * glj.unit_price.market_price).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
+                const marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
+                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj, tender) * marketPrice).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
         return rst;
         return rst;
     },
     },
-    'JGJXF': function () {//甲供机械费
+    'JGJXF': function (tender) {//甲供机械费
         let rst = 0;
         let rst = 0;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(baseMachineTypes.includes(glj.type) && glj.ratio_data.length === 0){
             if(baseMachineTypes.includes(glj.type) && glj.ratio_data.length === 0){
-                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj) * glj.unit_price.market_price).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
+                const marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
+                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj, tender) * marketPrice).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
         return rst;
         return rst;
     },
     },
-    'JGZCF': function () {//甲供主材费
+    'JGZCF': function (tender) {//甲供主材费
         let rst = 0;
         let rst = 0;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(glj.type === gljType.MAIN_MATERIAL && glj.ratio_data.length === 0){
             if(glj.type === gljType.MAIN_MATERIAL && glj.ratio_data.length === 0){
-                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj) * glj.unit_price.base_price).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
+                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj, tender) * calcBase.project.projectGLJ.getBasePrice(glj)).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
         return rst;
         return rst;
     },
     },
-    'JGSBF': function () {//甲供设备费
+    'JGSBF': function (tender) {//甲供设备费
         let rst = 0;
         let rst = 0;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(glj.type === gljType.EQUIPMENT){
             if(glj.type === gljType.EQUIPMENT){
-                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj) * glj.unit_price.market_price).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
+                const marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
+                rst = (rst + parseFloat(projectGljObject.getSupplyQuantityByGlj(glj, tender) * marketPrice).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
         return rst;
         return rst;
@@ -793,7 +797,7 @@ let baseFigureTemplate = {
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(glj.type === gljType.LABOUR && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
             if(glj.type === gljType.LABOUR && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
-                rst = (rst + parseFloat(glj[quantityType] * glj.unit_price.base_price).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
+                rst = (rst + parseFloat(glj[quantityType] * calcBase.project.projectGLJ.getBasePrice(glj)).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
         return rst;
         return rst;
@@ -804,7 +808,7 @@ let baseFigureTemplate = {
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(baseMaterialTypes.includes(glj.type) && glj.ratio_data.length === 0 && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
             if(baseMaterialTypes.includes(glj.type) && glj.ratio_data.length === 0 && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
-                rst = (rst + parseFloat(glj[quantityType] * glj.unit_price.base_price).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
+                rst = (rst + parseFloat(glj[quantityType] * calcBase.project.projectGLJ.getBasePrice(glj)).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
         return rst;
         return rst;
@@ -815,7 +819,7 @@ let baseFigureTemplate = {
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(baseMachineTypes.includes(glj.type) && glj.ratio_data.length === 0 && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
             if(baseMachineTypes.includes(glj.type) && glj.ratio_data.length === 0 && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
-                rst = (rst + parseFloat(glj[quantityType] * glj.unit_price.base_price).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
+                rst = (rst + parseFloat(glj[quantityType] * calcBase.project.projectGLJ.getBasePrice(glj)).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
         return rst;
         return rst;
@@ -826,7 +830,7 @@ let baseFigureTemplate = {
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(glj.type === gljType.LABOUR && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
             if(glj.type === gljType.LABOUR && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
-                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : glj.unit_price.market_price;
+                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
                 rst = (rst + parseFloat(glj[quantityType] * marketPrice).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
                 rst = (rst + parseFloat(glj[quantityType] * marketPrice).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
@@ -838,7 +842,7 @@ let baseFigureTemplate = {
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(baseMaterialTypes.includes(glj.type) && glj.ratio_data.length === 0 && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
             if(baseMaterialTypes.includes(glj.type) && glj.ratio_data.length === 0 && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
-                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : glj.unit_price.market_price;
+                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
                 rst = (rst + parseFloat(glj[quantityType] * marketPrice).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
                 rst = (rst + parseFloat(glj[quantityType] * marketPrice).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
@@ -850,7 +854,7 @@ let baseFigureTemplate = {
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(baseMachineTypes.includes(glj.type) && glj.ratio_data.length === 0 && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
             if(baseMachineTypes.includes(glj.type) && glj.ratio_data.length === 0 && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
-                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : glj.unit_price.market_price;
+                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
                 rst = (rst + parseFloat(glj[quantityType] * marketPrice).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
                 rst = (rst + parseFloat(glj[quantityType] * marketPrice).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
@@ -862,7 +866,7 @@ let baseFigureTemplate = {
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(glj.type === gljType.MAIN_MATERIAL && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
             if(glj.type === gljType.MAIN_MATERIAL && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
-                rst = (rst + parseFloat(glj[quantityType] * glj.unit_price.base_price).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
+                rst = (rst + parseFloat(glj[quantityType] * calcBase.project.projectGLJ.getBasePrice(glj)).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }
         return rst;
         return rst;
@@ -873,7 +877,7 @@ let baseFigureTemplate = {
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         let projGljs = calcBase.project.projectGLJ.datas.gljList;
         for(let glj of projGljs){
         for(let glj of projGljs){
             if(glj.type === gljType.EQUIPMENT && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
             if(glj.type === gljType.EQUIPMENT && (glj.supply === supplyType.JDYG || glj.supply === supplyText.JDYG)){
-                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : glj.unit_price.market_price;
+                let marketPrice = tender ? calcBase.project.projectGLJ.getTenderMarketPrice(glj) : calcBase.project.projectGLJ.getMarketPrice(glj);
                 rst = (rst + parseFloat(glj[quantityType] * marketPrice).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
                 rst = (rst + parseFloat(glj[quantityType] * marketPrice).toDecimal(decimalObj.bills.totalPrice)).toDecimal(decimalObj.bills.totalPrice);
             }
             }
         }
         }

+ 2 - 2
web/building_saas/main/js/views/project_glj_view.js

@@ -1015,7 +1015,7 @@ let projectGljObject={
         supplyQuantity = parseFloat(supplyQuantity);
         supplyQuantity = parseFloat(supplyQuantity);
         return supplyQuantity;
         return supplyQuantity;
     },
     },
-    getSupplyQuantityByGlj:function (glj) {
+    getSupplyQuantityByGlj:function (glj, tender) {
         //{"自行采购":0,"部分甲供":1,"完全甲供":2,"甲定乙供":3};
         //{"自行采购":0,"部分甲供":1,"完全甲供":2,"甲定乙供":3};
         let supply_quantity = glj.supply_quantity;
         let supply_quantity = glj.supply_quantity;
         switch (glj.supply){
         switch (glj.supply){
@@ -1025,7 +1025,7 @@ let projectGljObject={
             case 1:
             case 1:
                 break;
                 break;
             case 2:
             case 2:
-                supply_quantity = glj.quantity;
+                supply_quantity = tender ? glj.tenderQuantity : glj.quantity;
                 break;
                 break;
             case 3:
             case 3:
                 supply_quantity = 0;
                 supply_quantity = 0;

+ 3 - 1
web/building_saas/pm/js/pm_newMain.js

@@ -951,7 +951,9 @@ const projTreeObj = {
             const nodeIndent = node ? (node.depth() + 1) * indent +  node.depth() * levelIndent + imgWidth + 5 : 0;
             const nodeIndent = node ? (node.depth() + 1) * indent +  node.depth() * levelIndent + imgWidth + 5 : 0;
             const cellWidth = context.sheet.getCell(-1, context.col).width();
             const cellWidth = context.sheet.getCell(-1, context.col).width();
             const textLength = this.getAutoFitWidth(...arguments);
             const textLength = this.getAutoFitWidth(...arguments);
-            const lineNum = Math.ceil(textLength / (cellWidth - nodeIndent));
+            const tempNum = textLength / (cellWidth - nodeIndent);
+            const lineNum = tempNum % 1 > 0.92 ? Math.ceil(tempNum + 1) : Math.ceil(tempNum); // 不这么处理的话有些行高算出来不对
+            //const lineNum = Math.ceil(textLength / (cellWidth - nodeIndent));
             return lineNum * defaultHeight;
             return lineNum * defaultHeight;
         };
         };
         TreeNodeCellType.prototype.paint = function (ctx, value, x, y, w, h, style, options) {
         TreeNodeCellType.prototype.paint = function (ctx, value, x, y, w, h, style, options) {

+ 5 - 0
web/common/html/header.html

@@ -43,6 +43,11 @@
                     <a class="dropdown-item" href="/logout">退出登录</a>
                     <a class="dropdown-item" href="/logout">退出登录</a>
                 </div>
                 </div>
             </li>
             </li>
+            <% if (!versionName.includes('免费')) {%>
+                <li class="nav-item">
+                  <a href="user/buy" target="_blank"><img src="/web/building_saas/img/vip.png" data-toggle="tooltip" data-placement="bottom" data-original-title="专业版用户"></a>
+                </li> 
+                <% } %>  
             <% if (action === 'index' && controller === 'main') {%>
             <% if (action === 'index' && controller === 'main') {%>
             <li class="nav-item dropdown">
             <li class="nav-item dropdown">
                 <a class="nav-link dropdown-toggle" href="#" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"><i class="fa fa-wrench" data-placement="bottom"></i> 工具</a>
                 <a class="nav-link dropdown-toggle" href="#" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false"><i class="fa fa-wrench" data-placement="bottom"></i> 工具</a>

+ 5 - 2
web/users/html/user-buy.html

@@ -51,7 +51,7 @@
                             <div class="col-sm-4 mb-5">
                             <div class="col-sm-4 mb-5">
                                 <div class="card free-version">
                                 <div class="card free-version">
                                   <div class=" card-body">
                                   <div class=" card-body">
-                                    <h3 class="card-title text-white">免费版 </h3>
+                                    <h3 class="card-title">免费版 </h3>
                                       <p class="card-text">
                                       <p class="card-text">
                                     <!--  <ul class="pl-3">
                                     <!--  <ul class="pl-3">
                                           <li>只可创建 50 个单位工程</li>
                                           <li>只可创建 50 个单位工程</li>
@@ -76,7 +76,10 @@
                             <div class="col-sm-4 mb-5">
                             <div class="col-sm-4 mb-5">
                                 <div class="card pro-version">
                                 <div class="card pro-version">
                                   <div class=" card-body">
                                   <div class=" card-body">
-                                    <h3 class="card-title text-white">专业版</h3>
+                                    <h3 class="card-title">
+                                        <img src="/web/building_saas/img/vip.png">
+                                        专业版
+                                    </h3>
                                       <p class="card-text">
                                       <p class="card-text">
                                       <!--<ul class="pl-3">
                                       <!--<ul class="pl-3">
                                           <li>创建单位工程无限制</li>
                                           <li>创建单位工程无限制</li>