Jelajahi Sumber

【修改】申请发货单

莫绍宝 3 tahun lalu
induk
melakukan
4f458af7b9

+ 4 - 0
src/views/supply/apply/components/apply_form.vue

@@ -289,6 +289,7 @@ export default {
           item.orderId = item.id;
         })
         this.goodsList = data.orders;
+        this.screenForm.type = data.mainId;
       })
     },
 
@@ -457,6 +458,9 @@ export default {
     clickSubmitForm(status) {
       this.$refs.mainForm.validate((valid) => {
         if (valid) {
+          if(this.goodsList.length < 1) {
+            return this.$errorMsg('请添加引用');
+          }
           for(let i=0; i<this.goodsList.length; i++) {
             if(!this.goodsList[i].invoiceNum) {
               this.$errorMsg('请输入申请数量');

+ 3 - 0
src/views/supply/apply/components/engin_form.vue

@@ -624,6 +624,9 @@ export default {
     clickSubmitForm(status) {
       this.$refs.mainForm.validate((valid) => {
         if (valid) {
+          if(this.goodsList.length < 1) {
+            return this.$errorMsg('请添加引用');
+          }
           for(let i=0; i<this.goodsList.length; i++) {
             if(!this.goodsList[i].invoiceNum) {
               this.$errorMsg('请输入申请数量');