Browse Source

客户9.27

caojunjie 1 year ago
parent
commit
f30289629e

+ 3 - 0
src/views/tirePartsMall/basicData/customerInformation/detailsPage.vue

@@ -827,6 +827,9 @@ export default {
 
         if (valid) {
           this.loadingBtn = true;
+          if(!this.form.id) {
+              this.form.checkStatus = '通过'
+          }
           submit({
             ...this.form,
             code: this.form.cname,

+ 22 - 2
src/views/tirePartsMall/basicData/customerInformation/index.vue

@@ -44,7 +44,9 @@
             </template>
             <template slot-scope="{type,size, row, index }" slot="menu">
               <!-- <el-button :size="size" :type="type" :disabled="!row.enableOrNot" @click="editOpen(row, 2)">编辑</el-button> -->
-              <el-button :size="size" :type="type" :disabled="row.enableOrNot" @click.stop="rowDel(row)">删除</el-button>
+                <el-button v-if="row.checkStatus == '提交'" :size="size" :type="type" :disabled="row.enableOrNot" @click.stop="passThrough(row,'通过')">通过</el-button>
+                <el-button v-if="row.checkStatus == '提交'" :size="size" :type="type" :disabled="row.enableOrNot" @click.stop="passThrough(row,'驳回')">驳回</el-button>
+                <el-button :size="size" :type="type" :disabled="row.enableOrNot" @click.stop="rowDel(row)">删除</el-button>
             </template>
             <!-- <template slot="deliveryWarehouseName">
               <el-select v-model="search.deliveryWarehouseName" filterable clearable size="small" :disabled="disabled">
@@ -97,7 +99,8 @@ import {
   getCorpType,
   pageStatistics,
   remove,
-  customerList
+  customerList,
+    submit
 } from "@/api/tirePartsMall/basicData/customerInformation";
 import corpType from './components/index.vue'
 import { getToken } from "@/util/auth";
@@ -461,6 +464,23 @@ export default {
       this.page.currentPage = 1;
       this.page.pageSize = val;
     },
+      // 通过驳回方法
+      passThrough(row,type){
+          this.$confirm(`确定${type}数据?`, {
+              confirmButtonText: "确定",
+              cancelButtonText: "取消",
+              type: "warning"
+          }).then(()=>{
+              row.checkStatus = type
+              submit(row).then(res=>{
+                  this.$message({
+                      type: "success",
+                      message: `${type}成功!`
+                  });
+                  this.onLoad(this.page, this.search);
+              })
+          })
+      },
     rowDel(row, index, done) {
       this.$confirm("确定删除数据?", {
         confirmButtonText: "确定",

+ 23 - 4
src/views/tirePartsMall/basicData/customerInformation/js/optionList.js

@@ -16,7 +16,7 @@ export const option = {
   viewBtn: false,
   editBtn: false,
   delBtn: false,
-  menuWidth: 50,
+  menuWidth: 150,
   searchIcon: true,
   searchIndex: 2,
   column: [
@@ -97,6 +97,25 @@ export const option = {
       }]
     },
     {
+      label: "审核状态",
+      prop: "checkStatus",
+      overHidden: true,
+      hide: true,
+      search:true,
+      showColumn: false,
+      type: 'select',
+      dicData: [{
+        label: '提交',
+        value: '提交'
+      }, {
+        label: '通过',
+        value: '通过'
+      }, {
+        label: '驳回',
+        value: '驳回'
+      }]
+    },
+    {
       label: "合同金额",
       prop: "debitAmount",
       overHidden: true,
@@ -151,7 +170,7 @@ export const option = {
       showColumn: false,
       overHidden: true,
     },
-    
+
 
   ]
 }
@@ -232,7 +251,7 @@ export const option2 = {
         trigger: "blur"
       }
     ]
-  }, 
+  },
   {
     label: "地址",
     prop: "belongtoarea",
@@ -253,7 +272,7 @@ export const option2 = {
     ],
     filterable: true,
     cell: true,
-  }, 
+  },
   {
     label: '详细地址',
     prop: 'detailedAddress',