Browse Source

Merge remote-tracking branch 'origin/release-201827-wangcz' into release-201827-wangcz

yangc 7 years ago
parent
commit
ee2b28604d
1 changed files with 7 additions and 1 deletions
  1. 7 1
      components/mobile/center/outOfStorage/otherStorage.vue

+ 7 - 1
components/mobile/center/outOfStorage/otherStorage.vue

@@ -253,12 +253,14 @@
                 flag = 1
                 flag = 1
               } else if((val.erpReserve < val.qty) && this.switchType === 'OUTBOUND') {
               } else if((val.erpReserve < val.qty) && this.switchType === 'OUTBOUND') {
                 flag = 2
                 flag = 2
+              } else if(val.qty && Number(val.qty) <= 0) {
+                flag = 3
               } else if(val.qty) {
               } else if(val.qty) {
                 val.price ?
                 val.price ?
                   arr.push({price: Number(val.price), productId: val.productId, qty:Number(val.qty)}) :
                   arr.push({price: Number(val.price), productId: val.productId, qty:Number(val.qty)}) :
                   arr.push({productId: val.productId, qty:Number(val.qty)})
                   arr.push({productId: val.productId, qty:Number(val.qty)})
               } else {
               } else {
-                flag = 3
+                flag = 4
               }
               }
             }
             }
           })
           })
@@ -271,6 +273,10 @@
             return;
             return;
           }
           }
           if(flag === 3) {
           if(flag === 3) {
+            this.onRemind('填写的数量不能小于0!')
+            return;
+          }
+          if(flag === 4) {
             this.onRemind('请填写数量!')
             this.onRemind('请填写数量!')
             return;
             return;
           }
           }