浏览代码

退库入库退货库存增加限制

Epans 2 年之前
父节点
当前提交
272e703198
共有 3 个文件被更改,包括 46 次插入1 次删除
  1. 13 1
      src/views/custom/retreat/index.vue
  2. 20 0
      src/views/custom/returngoods/index.vue
  3. 13 0
      src/views/custom/storage/index.vue

+ 13 - 1
src/views/custom/retreat/index.vue

@@ -782,7 +782,19 @@ export default {
   computed: {
 
   },
-
+  watch: {
+    listAdd: {
+      deep: true,
+      handler: function (item) {
+          this.listAdd.forEach(function(i){
+            if(parseInt(i.quitNumber) > (parseInt(i.checkoutNumber)-parseInt(i.quitNumberC))){
+              i.quitNumber = parseInt(i.checkoutNumber)-parseInt(i.quitNumberC)
+            }
+                
+          })  
+      }
+    },
+  },
   created() {
     const that = this
     GetDataByName({ 'name': 'getUserPCButtons', 'parammaps': { 'jwt_username': Cookies.get('name') }}).then(response => {

+ 20 - 0
src/views/custom/returngoods/index.vue

@@ -828,6 +828,26 @@ export default {
 
   },
 
+  watch: {
+ 
+    listAdd: {
+      deep: true,
+      handler: function (item) {
+   
+          this.listAdd.forEach(function(i){
+            if(parseInt(i.refundNumber) > parseInt(i.reportery)){
+              i.refundNumber = i.reportery
+            }
+               
+          })
+
+           
+      }
+    },
+ 
+  },
+
+
   created() {
     const that = this
     GetDataByName({ 'name': 'getUserPCButtons', 'parammaps': { 'jwt_username': Cookies.get('name') }}).then(response => {

+ 13 - 0
src/views/custom/storage/index.vue

@@ -959,6 +959,19 @@ export default {
       return process.env.VUE_APP_BASE_API + 'authdata/ImportExcel'
     }
   },
+  watch: {
+    listAdd: {
+      deep: true,
+      handler: function (item) {
+          this.listAdd.forEach(function(i){
+            if(parseInt(i.reportery) > (parseInt(i.amount)-parseInt(i.receiveAmount))){
+              i.reportery = parseInt(i.amount)-parseInt(i.receiveAmount)
+            }
+                
+          })  
+      }
+    },
+  },
 
   created() {
     this.getDownList()