浏览代码

导入计量台账Excel调整

MaiXinRong 3 年之前
父节点
当前提交
1d2e6f4fe1
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      app/service/stage_stash.js

+ 1 - 1
app/service/stage_stash.js

@@ -97,7 +97,7 @@ class loadStageExcelTree {
             const contract_qty = source.is_tp ? 0 : node.contract_qty;
             const contract_tp = contract_qty
                 ? this.ctx.helper.mul(contract_qty, source.unit_price, this.decimal.tp)
-                : this.ctx.helper.round(node.contract_tp, this.decimal.tp);
+                : source.is_tp ? this.ctx.helper.round(node.contract_tp, this.decimal.tp) : 0;
 
             if (curStageBills) {
                 this.updateBills.push({ id: curStageBills.id, contract_qty: contract_qty, contract_tp: contract_tp, postil: node.postil || curStageBills.postil || '' });