浏览代码

本期数量变更金额,增加输入判断

MaiXinRong 1 月之前
父节点
当前提交
6c6f7bfa0f
共有 2 个文件被更改,包括 4 次插入1 次删除
  1. 3 1
      app/public/js/stage.js
  2. 1 0
      app/view/stage/index.ejs

+ 3 - 1
app/public/js/stage.js

@@ -1381,9 +1381,11 @@ $(document).ready(() => {
                     info.cancel = node.is_tp;
                     break;
                 case 'contract_tp':
-                case 'qc_tp':
                     info.cancel = !node.is_tp || node.settle_status === settleStatus.finish;
                     break;
+                case 'qc_tp':
+                    info.cancel = !node.is_tp || node.settle_status === settleStatus.finish || qcTpReadOnly || node.qc_qty || node.qc_minus_qty;
+                    break;
                 case 'is_tp':
                     info.cancel = true;
                     break;

+ 1 - 0
app/view/stage/index.ejs

@@ -548,6 +548,7 @@
         return this.replace(regExp, RepText);
     }
     const readOnly = <%- stage.readOnly || stage.revising || (stage.assist ? !!stage.assist.confirm : false) %>;
+    const qcTpReadOnly = <%- (ctx.session.sessionUser.is_admin ? 0 : 1) %>;
     const ledgerSpreadSetting = JSON.parse('<%- JSON.stringify(ledgerSpread) %>');
     ledgerSpreadSetting.localCache = {
         key: 'stage-bills',