Sfoglia il codice sorgente

1. 财务账面,过滤已关联的成本台账
2. 财务账面期列表,显示关联成本,本期入账,截止本期入账

MaiXinRong 14 ore fa
parent
commit
9a5eddac2b
2 ha cambiato i file con 10 aggiunte e 1 eliminazioni
  1. 4 1
      app/controller/cost_controller.js
  2. 6 0
      app/view/cost/book_list.ejs

+ 4 - 1
app/controller/cost_controller.js

@@ -128,11 +128,14 @@ module.exports = app => {
                 const stage_type = this.ctx.service.costStage.stageType.book.key;
                 const stages = await this.getTypeStages(ctx, stage_type);
                 const validLedgerStages = await this.ctx.service.costStage.getAllCheckedStages(ctx.tender.id, 'ledger', 'DESC');
+                for (const vls of validLedgerStages) {
+                    vls.beenRela = stages.findIndex(x => { return x.rela_stage.sid === vls.id; }) >= 0;
+                }
                 const renderData = {
                     stage_type,
                     auditType: audit.auditType,
                     stages,
-                    validLedgerStages,
+                    validLedgerStages: validLedgerStages.filter(x => { return !x.beenRela; }),
                     auditConst: audit.common,
                     jsFiles: this.app.jsFiles.common.concat(this.app.jsFiles.cost.cost_stage)
                 };

+ 6 - 0
app/view/cost/book_list.ejs

@@ -21,7 +21,10 @@
                     <tr class="text-center">
                         <th width="80px">期数</th>
                         <th width="70px">报审月份</th>
+                        <th width="70px">关联成本</th>
                         <th width="70px">创建人</th>
+                        <th>本期入账金额</th>
+                        <th>截止本期入账金额</th>
                         <th>本期入账金额(不含税)</th>
                         <th>截止本期入账金额(不含税)</th>
                         <th width="180px">审批进度</th>
@@ -35,7 +38,10 @@
                             <a href="/sp/<%- ctx.subProject.id %>/cost/tender/<%- ctx.tender.id %>/book/<%- s.stage_order %>/stage" target="_blank">第 <%- s.stage_order %> 期</a>
                         </td>
                         <td class="text-center"><%- s.stage_date %></td>
+                        <td class="text-center">第<%- s.rela_stage.sorder %>期</td>
                         <td class="text-center"><%- s.user_name %></td>
+                        <td class="text-right"><%- s.stage_tp.in_tp %></td>
+                        <td class="text-right"><%- s.stage_end_tp.in_tp %></td>
                         <td class="text-right"><%- s.stage_tp.in_excl_tax_tp %></td>
                         <td class="text-right"><%- s.stage_end_tp.in_excl_tax_tp %></td>
                         <td class="<%- auditConst.info[s.audit_status].class %>">