yusheng пре 6 месеци
родитељ
комит
63a93e474b
1 измењених фајлова са 16 додато и 10 уклоњено
  1. 16 10
      src/views/bpm/handleTask/components/sampleRecord/submit.vue

+ 16 - 10
src/views/bpm/handleTask/components/sampleRecord/submit.vue

@@ -64,8 +64,8 @@
     },
     data() {
       return {
-        form:{
-          reason:''
+        form: {
+          reason: ''
         }
       };
     },
@@ -88,10 +88,13 @@
           variables: {
             pass: !!status
           }
-        });
-        this.$emit('handleAudit', {
-          status,
-          title: status === 0 ? '驳回' : ''
+        }).then((res) => {
+          if (res.data.code != '-1') {
+            this.$emit('handleAudit', {
+              status,
+              title: status === 0 ? '驳回' : ''
+            });
+          }
         });
       },
       rejectTask(status) {
@@ -101,10 +104,13 @@
           variables: {
             pass: !!status
           }
-        });
-        this.$emit('handleAudit', {
-          status,
-          title: status === 0 ? '驳回' : ''
+        }).then((res) => {
+          if (res.data.code != '-1') {
+            this.$emit('handleAudit', {
+              status,
+              title: '驳回'
+            });
+          }
         });
       },