Browse Source

修改仓库管理附件、仓库定位为必填项

mxx 3 years ago
parent
commit
86d5c41550

+ 14 - 0
src/views/warehouse/warehouseManagementAdd.vue

@@ -379,6 +379,20 @@
             })
             return
           }
+          if (!this.deptBudgetList.addressUrl) {
+            this.$message({
+              message: '附件不能为空!',
+              type: 'warning',
+            })
+            return
+          }
+           if (!this.deptBudgetList.warehousePositioning) {
+            this.$message({
+              message: '仓库定位不能为空!',
+              type: 'warning',
+            })
+            return
+          }
 
           if (this.totalStorage <= 0) {
             this.$message({

+ 19 - 1
src/views/warehouse/warehouseManagementEdit.vue

@@ -479,7 +479,11 @@
             // if(this.deptBudgetList.addressUrl){
             //   this.fileList =  this._getFileList(this.deptBudgetList.addressUrl)
             // }
-            this.addressUrls = this.deptBudgetList.addressUrl.split(',')
+            if(this.deptBudgetList.addressUrl){
+              this.addressUrls = this.deptBudgetList.addressUrl.split(',')
+            }else{
+                this.addressUrls = []
+            }
             this.deptBudgetList.otherPersonPhone = this.deptBudgetList.otherPersonPhone.split(',')
             this.addressUrls.pop()
           })
@@ -557,6 +561,20 @@
           })
           return
         }
+        if (!this.deptBudgetList.addressUrl) {
+          this.$message({
+            message: '附件不能为空!',
+            type: 'warning',
+          })
+          return
+        }
+          if (!this.deptBudgetList.warehousePositioning) {
+          this.$message({
+            message: '仓库定位不能为空!',
+            type: 'warning',
+          })
+          return
+        }
         if (this.warehouseType == 1) {
           if (this.totalStorage <= 0) {
             this.$message({