浏览代码

Merge branch 'dev' of http://192.168.1.41:3000/maixinrong/Calculation into dev

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

+ 3 - 3
app/service/change_audit_list.js

@@ -683,7 +683,7 @@ module.exports = app => {
                             if (column === 'gcl_id' && d.b_code) updateCol.code = d.b_code;
                             if (column === 'gcl_id' && d.quantity !== undefined && changePosNum === 0) updateCol.oamount = d.quantity ? d.quantity : 0;
                             if (column === 'gcl_id' && d.unit_price !== undefined) updateCol.unit_price = d.unit_price ? d.unit_price : 0;
-                            if (column === 'gcl_id' && d.unit !== undefined) updateCol.unit = d.unit;
+                            if (column === 'gcl_id' && d.unit !== undefined) updateCol.unit = d.unit || '';
                             if (column === 'gcl_id' && d.name !== undefined) updateCol.name = d.name;
                             if (d.b_code !== undefined && d.b_code === null) {
                                 // 清单升级成了项目节,故删除变更已有的此清单,并找出需要重新计算的变更令
@@ -1099,9 +1099,9 @@ module.exports = app => {
                 const insertLedgerArr = [];
                 for (const l of ledgerList) {
                     const insertL = [
-                        l.id, l.code, l.b_code, l.name, l.unit, l.source, l.remark, l.ledger_id,
+                        l.id, l.code, l.b_code, l.name, (l.unit !== null ? l.unit : ''), l.source, l.remark, l.ledger_id,
                         l.ledger_pid, l.level, l.order, l.full_path, l.is_leaf, l.quantity, l.total_price,
-                        l.unit_price, l.drawing_code, l.memo, l.features, l.dgn_qty1, l.dgn_qty2, l.deal_qty, l.deal_tp,
+                        l.unit_price, l.drawing_code, l.memo, (l.features !== null ? l.features : ''), l.dgn_qty1, l.dgn_qty2, l.deal_qty, l.deal_tp,
                         l.sgfh_qty, l.sgfh_tp, l.sjcl_qty, l.sjcl_tp, l.qtcl_qty, l.qtcl_tp, l.node_type, l.crid, l.ccid,
                         l.tender_id, l.sgfh_expr, l.sjcl_expr, l.qtcl_expr, l.check_calc,
                         l.ex_memo1, l.ex_memo2, l.ex_memo3,