Selaa lähdekoodia

修改审核页面

caojunjie 4 vuotta sitten
vanhempi
commit
435ed2fee0
2 muutettua tiedostoa jossa 35 lisäystä ja 8 poistoa
  1. 4 3
      src/views/finance/charge/index.vue
  2. 31 5
      src/views/startApproval.vue

+ 4 - 3
src/views/finance/charge/index.vue

@@ -198,7 +198,7 @@
     />
 
     <!-- 添加或修改财务数据主对话框 -->
-    <el-dialog :close-on-click-modal="false" :title="title" :visible.sync="open" width="70%" append-to-body>
+    <el-dialog :close-on-click-modal="false" :title="title" :show-close="Xbutton" :visible.sync="open" width="70%" append-to-body>
       <el-form :model="queryParams" :rules="ruless" ref="ruless" :inline="true" v-show="showSearch"
                label-width="68px"
       >
@@ -596,6 +596,7 @@ export default {
         fMblno: '',    //提单号
         fName: ''      //货权方
       },
+      Xbutton:true,
       // 查询参数
       queryParams: {
         fId: null,
@@ -699,6 +700,7 @@ export default {
     adoPt(){
       this.approval = this.$route.query.data
       if (this.approval){
+        this.Xbutton = false
         this.approval = JSON.parse(this.approval)
         this.hide = false
         this.notChange = true
@@ -780,9 +782,8 @@ export default {
       let formDate = new window.FormData()
       formDate.append('tFee', JSON.stringify(this.queryParams))
       formDate.append('tFeeDo', JSON.stringify(this.increase_s))
-
       backCharge(formDate).then(response => {
-        console.log(response)
+        this.open = false
         this.msgSuccess('操作成功')
         this.getList()
       })

+ 31 - 5
src/views/startApproval.vue

@@ -35,6 +35,7 @@
 <script>
 import { listCharge } from '@/api/system/startApproval'
 import { queryUserVal } from '@/api/warehouseBusiness/agreement'
+import Global from '@/layout/components/global'
   export default {
     name: 'startApproval',
     data () {
@@ -79,21 +80,44 @@ import { queryUserVal } from '@/api/warehouseBusiness/agreement'
           type: 'warning'
         }).then(() => {
           return  listCharge(this.dataForm,'/warehouse/paths/approved')
-          }).then(({data}) => {
-            if (data && data.code === 200) {
+          }).then(data => {
+          console.log(data)
+            if (data && data.code == 200) {
               this.$message({
-                message: '操作成功',
+                message: '审核通过',
                 type: 'success',
                 duration: 600,
                 onClose: () => {
                   this.closeDia()
                 }
               })
+              this.visible = true
+              this.homePage()
             } else {
               this.$message.error(data.msg)
             }
           })
       },
+      homePage(){
+        let view = {
+          fullPath: "/finance/charge",
+          hash: "",
+          matched: Array(2),
+          meta: Object,
+          name: "Charge",
+          params: Object,
+          path: "/finance/charge",
+          query: Object,
+          title: "收费"
+        }
+        this.$router.push({ path: '/index'})
+        this.$store.dispatch('tagsView/delView', view).then(({ visitedViews }) => {
+          if (this.isActive(view)) {
+            this.toLastView(visitedViews, view)
+          }
+        })
+        Global.$emit("removeCache", "closeSelectedTag", view);
+      },
       approvalRejected () {
         this.$confirm(`是否驳回审批?`, '提示', {
           confirmButtonText: '确定',
@@ -102,15 +126,17 @@ import { queryUserVal } from '@/api/warehouseBusiness/agreement'
         }).then(() => {
           return listCharge(this.dataForm,'/warehouse/paths/approvalRejected')
           }).then(({data}) => {
-            if (data && data.code === 0) {
+            if (data && data.code == 200) {
               this.$message({
-                message: '操作成功',
+                message: '驳回审批',
                 type: 'success',
                 duration: 600,
                 onClose: () => {
                   this.closeDia()
                 }
               })
+              this.visible = true
+              this.homePage()
             } else {
               this.$message.error(data.msg)
             }