Prechádzať zdrojové kódy

核心企业确权审批

sqg 3 rokov pred
rodič
commit
7e48730323

+ 17 - 0
front-vue/src/api/service/credit/credit.js

@@ -143,4 +143,21 @@ export function openApproval(data){
       method: 'put',
       data: data
     })
+}
+
+//核心企业确权审批
+export function confirmationApproval(data){
+  return request({
+    url: '/sc-service/financeInf/confirmationApproval',
+    method: 'put',
+    data: data
+  })
+}
+
+// 查询当前操作员
+export function getUser() {
+  return request({
+    url: '/sc-service/ownCredit/getUser',
+    method: 'get'
+  })
 }

+ 43 - 2
front-vue/src/views/service/credit/credit.vue

@@ -217,13 +217,24 @@
           <el-button
            v-if="(scope.row.zfiCreateType == '1') &&
             (scope.row.zfiStatus == null || scope.row.zfiStatus == '')
-            && (scope.row.zfiCoreStatus == '03' || scope.row.zfiCoreStatus == '02')"
+            && (scope.row.zfiCoreStatus == '03' || scope.row.zfiCoreStatus == '02') 
+            && (scope.row.zfiCoreId == companyId)"
             size="mini"
             type="text"
+            icon="el-icon-s-check"
             @click="handleExam(scope.row)"
             v-hasPermi="['service:financeApply:coreApproval']"
           >核心开立审批</el-button>
           <el-button
+            v-if="scope.row.zfiStatus == '03' && scope.row.zfiCoreId == companyId 
+            && (scope.row.zfiCreateType == '0' || scope.row.zfiCreateType == '2')"
+            size="mini"
+            type="text"
+            icon="el-icon-s-check"
+            @click="handleConfirmationExam(scope.row)"
+            v-hasPermi="['service:financeApply:confirmationApproval']"
+          >确权审批</el-button>
+          <el-button
             type="text"
             size="mini"
             icon="el-icon-s-check"
@@ -261,7 +272,7 @@
 </template>
 
 <script>
-import { listCredit, coreApproval,informationApproval,approval,openApproval} from "@/api/service/credit/credit";
+import { listCredit, coreApproval, confirmationApproval, informationApproval,approval,openApproval, getUser } from "@/api/service/credit/credit";
 import Editor from '@/components/Editor';
 import {columnQuery,columnfilter} from "@/api/common/columnSetting";
 import ColumnSetting from '../../../components/Table/columnSetting.vue';
@@ -274,6 +285,8 @@ export default {
   },
   data() {
     return {
+      //当前登录企业Id
+      companyId:'',
       // 遮罩层
       loading: true,
       // 选中数组
@@ -378,6 +391,7 @@ export default {
     this.getDicts("zc_finance_state").then(response => {
       this.stateOptions = response.data;
     });
+    this.getUser();
     this.getList();
   },
   activated () {
@@ -387,12 +401,20 @@ export default {
     this.getDicts("zc_finance_state").then(response => {
       this.stateOptions = response.data;
     });
+    this.getUser();
     this.getList();
   },  
   mounted() {
     this.columnQuery();
   },
   methods: {
+    //获取操作员Id
+    getUser(){
+      getUser().then(response => {
+        debugger
+          this.companyId = response.data;
+        })
+    },
     //获取当前客户是否之前设置过列展示隐藏
     columnQuery(){
         //获取页面路径
@@ -542,6 +564,25 @@ export default {
           });
         });
     },
+    //确权审批
+    handleConfirmationExam(row){
+      this.$confirm("是否确认提交确权审批?", "警告", {
+          confirmButtonText: "确定",
+          cancelButtonText: "取消",
+          type: "warning"
+        }).then(function() {
+          return confirmationApproval(row);
+        }).then(() => {
+          this.getList();
+          this.msgSuccess("提交审批成功");
+        }).catch(() => {
+          this.$message({
+            type: "warning",
+            message: "已取消提交审批",
+
+          });
+        });
+    },
     //融资申请提交审批按钮
     handleApproval(row) {
       const zfiNumber = row.zfiNumber;