Browse Source

关联台账,不计价相关

MaiXinRong 2 years ago
parent
commit
7def610452
1 changed files with 5 additions and 5 deletions
  1. 5 5
      app/service/stage_rela.js

+ 5 - 5
app/service/stage_rela.js

@@ -85,7 +85,7 @@ class srCache {
             : [];
         this.ctx.helper.assignRelaData(pos, [
             { data: curPosData, fields: ['contract_qty', 'qc_qty', 'qc_minus_qty', 'postil', 'pid'], prefix: '', relaId: 'pid' },
-            { data: preStagePos, fields: ['contract_qty', 'qc_qty', 'qc_minus_qty', 'postil', 'pid'], prefix: 'pre_', relaId: 'pid' },
+            { data: preStagePos, fields: ['contract_qty', 'qc_qty', 'qc_minus_qty', 'pid'], prefix: 'pre_', relaId: 'pid' },
         ]);
         for (const p of pos) {
             p.gather_qty = this.ctx.helper.add(p.contract_qty, p.qc_qty);
@@ -143,7 +143,7 @@ class srCache {
                 gcl100.contract_tp = this.ctx.helper.add(gcl100.contract_tp, t.contract_tp);
                 gcl100.qc_tp = this.ctx.helper.add(gcl100.qc_tp, t.qc_tp);
             }
-            if (t.contract_qty || t.contract_tp || t.qc_qty || t.qc_tp) {
+            if (t.contract_qty || t.contract_tp || t.qc_qty || t.qc_tp || t.qc_minus_qty) {
                 this.stageBills.push({
                     tid: this.ctx.tender.id, sid: this.ctx.stage.id, sorder: this.ctx.stage.order,
                     rela_tid: this.stage.tid, rela_sid: this.stage.id, rela_sorder: this.stage.order,
@@ -153,7 +153,7 @@ class srCache {
                     postil: t.postil,
                 });
             }
-            if (t.end_contract_qty || t.end_contract_tp || t.end_qc_qty || t.end_qc_tp) {
+            if (t.end_contract_qty || t.end_contract_tp || t.end_qc_qty || t.end_qc_tp || t.qc_minus_qty) {
                 this.stageBillsFinal.push({
                     tid: this.ctx.tender.id, sid: this.ctx.stage.id, sorder: this.ctx.stage.order,
                     rela_tid: this.stage.tid, rela_sid: this.stage.id, rela_sorder: this.stage.order,
@@ -170,7 +170,7 @@ class srCache {
         this.stagePos = [];
         this.stagePosFinal = [];
         for (const t of this.pos.datas) {
-            if (t.contract_qty || t.qc_qty) {
+            if (t.contract_qty || t.qc_qty || t.qc_minus_qty) {
                 this.stagePos.push({
                     tid: this.ctx.tender.id, sid: this.ctx.stage.id, sorder: this.ctx.stage.order,
                     rela_tid: this.stage.tid, rela_sid: this.stage.id, rela_sorder: this.stage.order,
@@ -178,7 +178,7 @@ class srCache {
                     contract_qty: t.contract_qty, contract_expr: t.contract_expr, qc_qty: t.qc_qty, qc_minus_qty: t.qc_minus_qty, postil: t.postil,
                 });
             }
-            if (t.end_contract_qty || t.end_qc_qty) {
+            if (t.end_contract_qty || t.end_qc_qty || t.qc_minus_qty) {
                 this.stagePosFinal.push({
                     tid: this.ctx.tender.id, sid: this.ctx.stage.id, sorder: this.ctx.stage.order,
                     rela_tid: this.stage.tid, rela_sid: this.stage.id, rela_sorder: this.stage.order,