Explorar o código

计量台账,清单,调用变更令,取消原调用报错

MaiXinRong %!s(int64=6) %!d(string=hai) anos
pai
achega
f449e2038a
Modificáronse 1 ficheiros con 2 adicións e 2 borrados
  1. 2 2
      app/service/stage_bills.js

+ 2 - 2
app/service/stage_bills.js

@@ -220,11 +220,11 @@ module.exports = app => {
             const info = this.ctx.tender.info;
             const precision = this.ctx.helper.findPrecision(info.precision, ledgerBills.unit);
             const updateData = {};
-            if (data.contract_qty) {
+            if (data.contract_qty !== undefined) {
                 updateData.contract_qty = this.round(data.contract_qty, precision.value);
                 updateData.contract_tp = this.ctx.helper.mul(updateData.contract_qty, ledgerBills.unit_price, info.decimal.tp);
             }
-            if (data.qc_qty) {
+            if (data.qc_qty !== undefined) {
                 updateData.qc_qty = this.round(data.qc_qty, precision.value);
                 updateData.qc_tp = this.ctx.helper.mul(updateData.qc_qty, ledgerBills.unit_price, info.decimal.tp);
             }