zhongtianhaoyuan 2 سال پیش
والد
کامیت
479eba3673
2فایلهای تغییر یافته به همراه68 افزوده شده و 56 حذف شده
  1. 58 51
      src/views/profitable/cashoutaduit.vue
  2. 10 5
      src/views/profitable/cashoutaduitNQ.vue

+ 58 - 51
src/views/profitable/cashoutaduit.vue

@@ -209,7 +209,7 @@
           </div>
           </div>
 
 
           <span slot="footer" class="dialog-footer">
           <span slot="footer" class="dialog-footer">
-            <el-button @click="rejectshow = false">取 消</el-button>
+            <el-button @click="cancelShow">取 消</el-button>
             <el-button type="primary" @click="rejectclick">确 定</el-button>
             <el-button type="primary" @click="rejectclick">确 定</el-button>
           </span>
           </span>
         </el-dialog>
         </el-dialog>
@@ -263,7 +263,7 @@ export default {
         date: 20
         date: 20
       }
       }
       ], //货值
       ], //货值
-      auditList: [],//审核附件
+      auditList: "",//审核附件
       auditUrl: ""
       auditUrl: ""
 
 
     }
     }
@@ -272,6 +272,11 @@ export default {
     this.getList()
     this.getList()
   },
   },
   methods: {
   methods: {
+    cancelShow() {
+      this.rejectshow = false
+      this.auditList = [],//审核附件
+        this.auditUrl = ""
+    },
     auditUrlChange() {//审核附件
     auditUrlChange() {//审核附件
       this.$refs.upload
       this.$refs.upload
         .handleSaveBill()
         .handleSaveBill()
@@ -296,16 +301,9 @@ export default {
       this.rejectshow = false
       this.rejectshow = false
     },
     },
     pass() {
     pass() {
-      this.$confirm('确认通过请款信息?', '提示', {
-        confirmButtonText: '确定',
-        cancelButtonText: '取消',
-        type: 'warning'
-      })
-        .then(() => {
-          this.title = '通过'
-          this.rejectshow = true
 
 
-        })
+      this.title = '通过'
+      this.rejectshow = true
     },
     },
     returnsales() {
     returnsales() {
       this.$router.go(-1)
       this.$router.go(-1)
@@ -315,46 +313,55 @@ export default {
       this.rejectshow = true
       this.rejectshow = true
     },
     },
     rejectclick() {
     rejectclick() {
-      if (this.title == '驳回') {
-        woekflowhandle({
-          taskId: this.deptBudgetList.taskId,
-          approved: false,
-          auditMind: this.textarea+"##"+this.auditUrl,
-          needReapply: true,
-        }).toPromise()
-          .then((response) => {
-            this.$message({
-              message: '驳回成功!',
-              type: 'success',
-            })
-            this.rejectshow = false
-            this.$router.go(-1)
-          }).catch((response) => {
-            this.$message({
-              message: '驳回失败!',
-              type: 'error',
-            })
-          })
-      } else {
-        woekflowhandle({
-          taskId: this.deptBudgetList.taskId,
-          approved: true,
-          auditMind: this.textarea+"##"+this.auditUrl,
-          needReapply: true,
-        }).toPromise()
-          .then((response) => {
-            this.$message({
-              message: '通过成功!',
-              type: 'success',
-            })
-            this.$router.go(-1)
-          }).catch((response) => {
-            this.$message({
-              message: '通过失败!',
-              type: 'error',
-            })
-          })
-      }
+      this.$confirm('确认' + this.title + '请款信息?', '提示', {
+        confirmButtonText: '确定',
+        cancelButtonText: '取消',
+        type: 'warning'
+      })
+        .then(() => {
+          if (this.title == '驳回') {
+            woekflowhandle({
+              taskId: this.deptBudgetList.taskId,
+              approved: false,
+              auditMind: this.textarea + "##" + this.auditUrl,
+              needReapply: true,
+            }).toPromise()
+              .then((response) => {
+                this.$message({
+                  message: '驳回成功!',
+                  type: 'success',
+                })
+                this.rejectshow = false
+                this.$router.go(-1)
+              }).catch((response) => {
+                this.$message({
+                  message: '驳回失败!',
+                  type: 'error',
+                })
+              })
+          } else {
+            woekflowhandle({
+              taskId: this.deptBudgetList.taskId,
+              approved: true,
+              auditMind: this.textarea + "##" + this.auditUrl,
+              needReapply: true,
+            }).toPromise()
+              .then((response) => {
+                this.$message({
+                  message: '通过成功!',
+                  type: 'success',
+                })
+                this.$router.go(-1)
+              }).catch((response) => {
+                this.$message({
+                  message: '通过失败!',
+                  type: 'error',
+                })
+              })
+          }
+
+        })
+
 
 
     },
     },
     getList() {
     getList() {

+ 10 - 5
src/views/profitable/cashoutaduitNQ.vue

@@ -265,7 +265,7 @@
           :size-limit="size" @onChange="auditUrlChange" @uploadSuccess="uploadSuccess" />
           :size-limit="size" @onChange="auditUrlChange" @uploadSuccess="uploadSuccess" />
       </div>
       </div>
       <span slot="footer" class="dialog-footer">
       <span slot="footer" class="dialog-footer">
-        <el-button @click="rejectshow = false">取 消</el-button>
+        <el-button @click="cancelShow">取 消</el-button>
         <el-button type="primary" @click="title == '驳回' ? rejectclick() : pass()">确 定</el-button>
         <el-button type="primary" @click="title == '驳回' ? rejectclick() : pass()">确 定</el-button>
       </span>
       </span>
     </el-dialog>
     </el-dialog>
@@ -339,7 +339,7 @@ export default {
       }
       }
       ], //货值
       ], //货值
       auditList: [],//审核附件
       auditList: [],//审核附件
-      auditUrl:""
+      auditUrl: ""
     }
     }
   },
   },
   activated() {
   activated() {
@@ -362,6 +362,11 @@ export default {
     }
     }
   },
   },
   methods: {
   methods: {
+    cancelShow() {
+      this.rejectshow = false
+      this.auditList = [],//审核附件
+        this.auditUrl = ""
+    },
     sourceChange(e) {
     sourceChange(e) {
       if (e == '') {
       if (e == '') {
         this.goodsSource = '全部客户'
         this.goodsSource = '全部客户'
@@ -500,7 +505,7 @@ export default {
       if (!this.auditUrl) {
       if (!this.auditUrl) {
         this.auditUrl = data.appendixPath
         this.auditUrl = data.appendixPath
       } else {
       } else {
-        this.auditUrl =  this.auditUrl+"," + data.appendixPath
+        this.auditUrl = this.auditUrl + "," + data.appendixPath
       }
       }
     },
     },
     modeselect(e) {
     modeselect(e) {
@@ -797,7 +802,7 @@ export default {
           woekflowhandle({
           woekflowhandle({
             taskId: this.deptBudgetList.taskId,
             taskId: this.deptBudgetList.taskId,
             approved: true,
             approved: true,
-            auditMind: this.textarea+"##"+this.auditUrl,
+            auditMind: this.textarea + "##" + this.auditUrl,
             needReapply: true,
             needReapply: true,
           }).toPromise()
           }).toPromise()
             .then((response) => {
             .then((response) => {
@@ -819,7 +824,7 @@ export default {
       woekflowhandle({
       woekflowhandle({
         taskId: this.deptBudgetList.taskId,
         taskId: this.deptBudgetList.taskId,
         approved: false,
         approved: false,
-        auditMind: this.textarea+"##"+this.auditUrl,
+        auditMind: this.textarea + "##" + this.auditUrl,
         needReapply: true,
         needReapply: true,
       }).toPromise()
       }).toPromise()
         .then((response) => {
         .then((response) => {