ellisran 1 день назад
Родитель
Сommit
8ad074330e
2 измененных файлов с 10 добавлено и 34 удалено
  1. 1 31
      app/public/js/contract_detail.js
  2. 9 3
      app/view/contract/detail.ejs

+ 1 - 31
app/public/js/contract_detail.js

@@ -153,7 +153,7 @@ $(document).ready(function() {
     };
     const contractTree = createNewPathTree('revise', treeSetting);
 
-    const contractDetail = ['c_code', 'name', 'price', 'supplement_price', 'pay_price', 'debit_price','yf_price', 'sf_price', 'party_a', 'party_a_user', 'party_b', 'party_b_user', 'sign_date', 'address', 'entity', 'bank', 'bank_account', 'remark', 'settle_code', 'tax', 'create_time'];
+    const contractDetail = ['c_code', 'name', 'price', 'supplement_price', 'total_price', 'pay_price', 'debit_price','yf_price', 'sf_price', 'party_a', 'party_a_user', 'party_b', 'party_b_user', 'sign_date', 'address', 'entity', 'bank', 'bank_account', 'remark', 'settle_code', 'tax', 'create_time'];
 
     // 清单 相关方法&绑定spreadjs事件
     const contractTreeSpreadObj = {
@@ -349,17 +349,6 @@ $(document).ready(function() {
                         } else if (c === 'sign_date') {
                             $('#htdetail_' + c).text(node[c] ? moment(node[c]).format('YYYY-MM-DD') : '');
                             continue;
-                        } else if (c === 'price') {
-                            $('#htdetail_' + c).text(node.total_price || '');
-                            continue;
-                        } else if (c === 'supplement_price') {
-                            if (node[c]) {
-                                $('#show-supplement-price').show();
-                            } else {
-                                $('#show-supplement-price').hide();
-                            }
-                            $('#show-supplement-price').attr('data-original-title', '含补充合同金额:' + node[c]);
-                            continue;
                         }
                         $('#htdetail_' + c).text(node[c] || '');
                     }
@@ -673,17 +662,6 @@ $(document).ready(function() {
                     } else if (c === 'sign_date') {
                         $('#htdetail_' + c).text(node[c] ? moment(node[c]).format('YYYY-MM-DD') : '');
                         continue;
-                    } else if (c === 'price') {
-                        $('#htdetail_' + c).text(node.total_price || '');
-                        continue;
-                    } else if (c === 'supplement_price') {
-                        if (node[c]) {
-                            $('#show-supplement-price').show();
-                        } else {
-                            $('#show-supplement-price').hide();
-                        }
-                        $('#show-supplement-price').attr('data-original-title', '含补充合同金额:' + node[c]);
-                        continue;
                     }
                     $('#htdetail_' + c).text(node[c] || '');
                 }
@@ -1871,8 +1849,6 @@ $(document).ready(function() {
                     } else if (c === 'tax') {
                         $('#htdetail_' + c).html('<input type="number" min="0" max="100" step="1" class="form-control form-control-sm" value="' + (node[c] ? node[c] : '') + '">');
                         continue;
-                    } else if (c === 'supplement_price') {
-                        continue;
                     }
                     $('#htdetail_' + c).html('<input type="text" class="form-control form-control-sm" value="' + node[c] + '">');
                 }
@@ -1902,8 +1878,6 @@ $(document).ready(function() {
                     } else if (c === 'remark') {
                         data[c] = $('#htdetail_' + c + ' textarea').val();
                         continue;
-                    } else if (c === 'supplement_price') {
-                       continue;
                     }
                     data[c] = $('#htdetail_' + c + ' input').val();
                 }
@@ -1987,10 +1961,6 @@ $(document).ready(function() {
                 if ($('#htdetail_' + c) && $('#htdetail_' + c).hasClass('change-input-td')) {
                     if (c === 'sign_date') {
                         $('#htdetail_' + c).text(node[c] ? moment(node[c]).format('YYYY-MM-DD') : '');
-                    } else if (c === 'price') {
-                        $('#htdetail_' + c).text(node.total_price || '');
-                    } else if (c === 'supplement_price') {
-                        continue;
                     } else {
                         $('#htdetail_' + c).html(node[c]);
                     }

+ 9 - 3
app/view/contract/detail.ejs

@@ -117,12 +117,20 @@
                                         <td width="20%" class="change-input-td" id="htdetail_tax"></td>
                                     </tr>
                                     <tr>
-                                        <th class="text-center align-middle">合同金额 <a href="javascript:void(0);" data-toggle="tooltip" data-placement="bottom" id="show-supplement-price" title="" data-original-title="补充合同金额:"><i class="fa fa-question-circle-o"></i></a></th>
+                                        <th class="text-center align-middle">合同金额</th>
                                         <td class="change-input-td" id="htdetail_price"></td>
+                                        <th class="text-center align-middle">补充合同金额</th>
+                                        <td class="" id="htdetail_supplement_price"></td>
+                                        <th class="text-center align-middle">合同金额</th>
+                                        <td class="" id="htdetail_total_price"></td>
+                                    </tr>
+                                    <tr>
                                         <th class="text-center align-middle"><% if (ctx.contract_type === contractConst.type.income) { %>累计回款(P)<% } else if (ctx.contract_type === contractConst.type.expenses) { %>累计付款(P)<% } %></th>
                                         <td id="htdetail_pay_price"></td>
                                         <th class="text-center align-middle">累计扣款(K)</th>
                                         <td id="htdetail_debit_price"></td>
+                                        <th></th>
+                                        <td></td>
                                     </tr>
                                     <tr>
                                         <th class="text-center align-middle"><% if (ctx.contract_type === contractConst.type.income) { %>累计应回(S=P-K)<% } else if (ctx.contract_type === contractConst.type.expenses) { %>累计应付(S=P-K)<% } %></th>
@@ -163,8 +171,6 @@
                                         <td id="htdetail_settle_code"></td>
                                         <th class="text-center align-middle">创建时间</th>
                                         <td id="htdetail_create_time"></td>
-                                    </tr>
-                                    <tr>
                                         <th class="text-center align-middle">备注</th>
                                         <td class="change-input-td" colspan="5" id="htdetail_remark"></td>
                                     </tr>