瀏覽代碼

fix: 增加提交作废前限制

zh 2 年之前
父節點
當前提交
01b02cb2d0
共有 1 個文件被更改,包括 7 次插入0 次删除
  1. 7 0
      src/views/sales_policy/components/cancal.vue

+ 7 - 0
src/views/sales_policy/components/cancal.vue

@@ -317,6 +317,13 @@ export default {
         this.$errorMsg('物料不能为空')
         return
       }
+      for (let i = 0; i < this.tableData.length; i++) {
+        if (!this.tableData[i].number) {
+          this.$errorMsg('物料不能为空')
+          return
+        }
+      }
+
       const policyIds = this.policyList.map(k => k.id).join(',')
       const materialIds = this.tableData.map(k => k.id).join(',')
       cancalMaterialPolicy({