浏览代码

【修改】申请发货单

莫绍宝 3 年之前
父节点
当前提交
4f458af7b9
共有 2 个文件被更改,包括 7 次插入0 次删除
  1. 4 0
      src/views/supply/apply/components/apply_form.vue
  2. 3 0
      src/views/supply/apply/components/engin_form.vue

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

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

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

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