Browse Source

bug 修复

lilei 2 years ago
parent
commit
c5223b649d
1 changed files with 17 additions and 0 deletions
  1. 17 0
      src/views/salesReturnManagement/receiveCheck/checking.vue

+ 17 - 0
src/views/salesReturnManagement/receiveCheck/checking.vue

@@ -199,6 +199,23 @@ export default {
         }
       })
       console.log(obj)
+      // 如果批量修改良品数量为0
+      const hasError = _this.rowSelectionInfo.selectedRows.filter(item => item.backStockQty > 0)
+      if (val == 0 && this.actionType == 1 && hasError.length) {
+        this.$confirm({
+          title: '提示',
+          content: '是否将返库数量同样设置为0?',
+          centered: true,
+          closable: true,
+          onOk () {
+            _this.plSave(obj)
+          }
+        })
+      } else {
+        _this.plSave(obj)
+      }
+    },
+    plSave (obj) {
       const fun = this.actionType == 1 ? updateBatchGoodQty : updateBatchBackStockQty
       this.spinning = true
       fun(obj).then(res => {