Browse Source

TASK #3926 计量进度界面,期望在"上一流程审核时间"与"0号台账"之间增加"签约合同价"列,获取合同参数中的"签约合同价"金额

MaiXinRong 3 years ago
parent
commit
216ef48ab3
1 changed files with 15 additions and 9 deletions
  1. 15 9
      app/public/js/tender_list_progress.js

+ 15 - 9
app/public/js/tender_list_progress.js

@@ -197,6 +197,7 @@ function calculateParent(node) {
         node.gather_tp = 0;
         node.sum_tp = 0;
         node.lastStage = 0;
+        node.deal_tp = 0;
         for (const c of node.children) {
             calculateParent(c);
             node.end_qc_tp = ZhCalc.add(node.end_qc_tp, c.end_qc_tp);
@@ -206,6 +207,7 @@ function calculateParent(node) {
             node.lastStage = c.cid
                 ? Math.max(node.lastStage, c.lastStage)
                 : (c.lastStage ? Math.max(node.lastStage, c.lastStage.order) : node.lastStage);
+            node.deal_tp = ZhCalc.add(node.deal_tp, c.deal_tp);
         }
     }
 }
@@ -322,26 +324,29 @@ function recursiveGetTenderNodeHtml (node, arr, pid) {
     }
     html.push('</td>');
     // 计量进度
-    html.push('<td style="width: 10%">');
+    html.push('<td style="width: 8%">');
     if (!node.cid && node.cur_flow) {
         html.push(node.cur_flow.title + ' (' + '<span class="' + node.cur_flow.status_class +'">' + node.cur_flow.status + '</span>' + ')');
     }
     html.push('</td>');
     // 当前流程
-    html.push('<td style="width: 10%">');
+    html.push('<td style="width: 8%">');
     if (!node.cid && node.cur_flow) {
         html.push(node.cur_flow.name + ' ' + '<span class="' + node.cur_flow.status_class +'">' + node.cur_flow.status + '</span>');
     }
     html.push('</td>');
     // 上一流程审批时间
-    html.push('<td style="width: 10%">');
+    html.push('<td style="width: 8%">');
     if (!node.cid && node.pre_flow) {
         html.push(node.pre_flow.name + ' ' + moment(node.pre_flow.time).format('YYYY-MM-DD'));
     }
     html.push('</td>');
+    // 签约合同价
+    html.push('<td width="8%" class="text-right">');
+    html.push(node.deal_tp ? node.deal_tp : '');
+    html.push('</td>');
     // 总价
-    html.push('<td width="10%" class="text-right">');
-    const sum = node.lastStage ? ZhCalc.add(node.total_price, node.lastStage.end_qc_tp) : node.total_price;
+    html.push('<td width="8%" class="text-right">');
     html.push(node.sum_tp ? node.sum_tp : '');
     html.push('</td>');
     // 截止本期累计完成/本期完成/未完成
@@ -367,10 +372,11 @@ function getTenderTreeHtml () {
         html.push('<table class="table table-hover table-bordered">');
         html.push('<thead style="position: fixed;left:56px;top: 34px;">', '<tr>');
         html.push('<th style="width: 25%" class="text-center">', '标段名称', '</th>');
-        html.push('<th class="text-center" style="width: 10%">', '计量进度', '</th>');
-        html.push('<th class="text-center" style="width: 10%">', '当前流程', '</th>');
-        html.push('<th class="text-center" style="width: 10%">', '上一流程审批时间', '</th>');
-        html.push('<th style="width: 10%" class="text-center">', '总价 <i class="fa fa-question-circle text-primary"  data-placement="bottom" data-toggle="tooltip" data-original-title="0号台账+截止本期数量变更"></i>', '</th>');
+        html.push('<th class="text-center" style="width: 8%">', '计量进度', '</th>');
+        html.push('<th class="text-center" style="width: 8%">', '当前流程', '</th>');
+        html.push('<th class="text-center" style="width: 8%">', '上一流程审批时间', '</th>');
+        html.push('<th class="text-center" style="width: 8%">', '签约合同价', '</th>');
+        html.push('<th style="width: 8%" class="text-center">', '总价 <i class="fa fa-question-circle text-primary"  data-placement="bottom" data-toggle="tooltip" data-original-title="0号台账+截止本期数量变更"></i>', '</th>');
         html.push('<th style="width: 35%" class="text-center">', '截止上期完成/本期完成/未完成', '</th>');
         html.push('</tr>', '</thead>');
         parentId = 0;