Sfoglia il codice sorgente

Merge branch 'master' of http://git.keao.tech/SupplyChain/front

ch 3 anni fa
parent
commit
4a630f7741

+ 1 - 1
front-vue/src/router/index.js

@@ -279,7 +279,7 @@ export const constantRoutes = [
         meta: { title: '修改授信信息',noCache: true }
       },
       {
-        path: 'detailCreditLine/:zfpcrId/:zfiAmount/:usableAmount',
+        path: 'detailCreditLine/:zfpcrId/:zfiAmount/:usableAmount/:companyType',
         component: (resolve) => require(['@/views/service/creditLine/detailCreditLine'], resolve),
         name: 'detailCreditLine',
         meta: { title: '授信信息详情',noCache: true }

+ 43 - 6
front-vue/src/views/service/credit/confirmationAudit.vue

@@ -277,6 +277,14 @@
                 <pdf-show :pdfFileList="pdfFileList" :zfiId="this.form.zfiId" :parent="parent">
                 </pdf-show>
             </el-dialog>
+             <!--去融资-->
+            <el-dialog  :visible.sync="goShow" width="300px"  append-to-body :before-close = "cancelGo" center>
+                    <p>恭喜您成功签收一笔融信</p>
+                    <div slot="footer" class="dialog-footer">
+                        <el-button type="primary" @click="goFinance">去融资</el-button>
+                        <el-button @click="cancelGo">取 消</el-button>
+                    </div>    
+            </el-dialog>
            
         </el-tab-pane>
         <!-- 签署合同-->
@@ -319,6 +327,7 @@ import {accAdd} from "@/utils/calculation";
 import {isOpenApproval} from "@/api/service/credit/approvalRelatedCredit";
 import {getToken} from "@/utils/auth";
 import pdfShow from "./pdfShow";
+import Cookies from 'js-cookie';
 export default {
     name: "addCredit",
     components: {pdfShow},
@@ -448,6 +457,8 @@ export default {
             pdfFileList : [],
             pdfShowDialog : false,
             parent : this,
+            //显示去融资框
+            goShow:false
         };
     },
     watch:{
@@ -1131,16 +1142,42 @@ export default {
                     });
             contractSigning(this.form).then((response) => {
                 loading.close();
-                this.msgSuccess("确权成功,融信已提交"+this.form.receiveName+"签收");
-                this.$store.dispatch(
-                    "tagsView/delView",
-                    this.$route
-                );
-                this.$router.go(-1);
+                //融资申请
+                if(this.zfiCreateType == '0'){
+                    this.msgSuccess("确权成功,融信已提交"+this.form.receiveName+"签收");
+                    this.$store.dispatch(
+                        "tagsView/delView",
+                        this.$route
+                    );
+                    this.$router.go(-1);
+                }else if(this.zfiCreateType == '2'){//供应商开立,盖章后改为已生效
+                        this.goShow = true;
+                }
             }).catch((response) => {
                 loading.close();
             });
     },
+    //回到父页
+    cancelGo(){
+        this.goShow = false;
+        this.$store.dispatch(
+            "tagsView/delView",
+            this.$route
+        );
+        this.$router.go(-1);
+    },
+    //去融资
+    goFinance(){
+        //关闭当前页
+         this.$store.dispatch(
+            "tagsView/delView",
+            this.$route
+        );
+        //关闭弹框
+        this.goShow = false;
+        Cookies.set("/credit/goFinance/"+this.zfiId + "/", this.$route.fullPath)
+        this.$router.push({ path: "/credit/goFinance/"+this.zfiId + "/" });
+    }
        
     }
 };

+ 12 - 6
front-vue/src/views/service/credit/creditSeal.vue

@@ -811,6 +811,8 @@ export default {
                     });
             contractSigning(this.form).then((response) => {
                 loading.close();
+                //关闭弹窗,回到父页
+                this.goParent();
                 //核心开立盖章
                 if(this.form.zfiCreateType == '1' && this.form.zfiCoreStatus == '01' && !this.form.zfiStatus){
                     this.msgSuccess("开立成功,融信已提交"+this.form.receiveName+"签收");
@@ -818,12 +820,6 @@ export default {
                     //融资开立盖章
                     this.msgSuccess("开立成功,待:"+this.form.openName+"确权;确权结果请留意待办事项与站内消息");
                 }
-
-                this.$store.dispatch(
-                    "tagsView/delView",
-                    this.$route
-                );
-                this.$router.go(-1);
             }).catch((response) => {
                 loading.close();
             });
@@ -960,6 +956,16 @@ export default {
     closePdfShow(){
         this.pdfShowDialog = false;
     },
+    //返回到列表页
+     goParent(){
+        this.pdfShowDialog = false;
+        this.$store.dispatch(
+            "tagsView/delView",
+            this.$route
+            );
+        this.$router.go(-1);
+    },
+
     
     }
 };

+ 16 - 18
front-vue/src/views/service/credit/pdfShow.vue

@@ -106,8 +106,8 @@
                 <img :src="'data:image/jpeg;base64,' + this.fileUrl" style="overflow: auto; width: 100%; height: 100%;"/>
             </el-dialog>
             <!--去融资-->
-            <el-dialog  :visible.sync="goShow" width="500px"  append-to-body :before-close = "cancelGo" center>
-                    <span>恭喜您成功签收一笔融信</span>
+            <el-dialog  :visible.sync="goShow" width="300px"  append-to-body :before-close = "cancelGo" center>
+                    <p>恭喜您成功签收一笔融信</p>
                     <div slot="footer" class="dialog-footer">
                         <el-button type="primary" @click="goFinance">去融资</el-button>
                         <el-button @click="cancelGo">取 消</el-button>
@@ -525,29 +525,21 @@ export default {
                 this.closePdfShow();
                 //确权:状态为待确权
                 if(this.zfiStatus == '00'){
-                     this.msgSuccess("确权成功,融信已提交,"+this.receiveName+"签收");
-                     this.$store.dispatch(
-                        "tagsView/delView",
-                        this.$route
-                        );
-                     this.$router.go(-1);
+                    if(this.zfiCreateType == '0'){//申请
+                         this.msgSuccess("确权成功,融信已提交,"+this.receiveName+"签收");
+                         this.goParent();
+                    }else if(this.zfiCreateType == '2'){//供应商开立
+                          this.goShow = true;
+                    }
                 }else if(this.zfiStatus == '01' && this.zfiCreateType == '0'){//签收
                      this.goShow = true;
                 }else if(this.zfiCreateType == '1' && this.zfiCoreStatus == '01' && !this.zfiStatus){//核心开立
                     this.msgSuccess("开立成功,融信已提交"+this.receiveName+"签收");
-                    this.$store.dispatch(
-                        "tagsView/delView",
-                        this.$route
-                        );
-                    this.$router.go(-1);
+                    this.goParent();
                 }else if(this.zfiCreateType == '2' && this.zfiPlatformStatus == '01' && this.zfiSupplierStatus == '01' && !this.zfiStatus){
                     //融资开立盖章
                     this.msgSuccess("开立成功,待:"+this.openName+"确权;确权结果请留意待办事项与站内消息");
-                    this.$store.dispatch(
-                        "tagsView/delView",
-                        this.$route
-                        );
-                     this.$router.go(-1);
+                    this.goParent();
                 }else if(scope.row.zfiCreateType == '1' && this.zfiSupplierStatus == '01' && this.zfiPlatformStatus == '01'){//补充资料
                      this.goShow = true;
                 }
@@ -611,6 +603,10 @@ export default {
     closePdfShow(){
         this.parent.closePdfShow();
     },
+    //返回到列表页
+    goParent(){
+       this.parent.goParent();
+    },
     //去融资
     goFinance(){
         //关闭当前页
@@ -620,6 +616,8 @@ export default {
             );
         //关闭弹框
         this.goShow = false;
+        //关闭文件弹框
+        this.closePdfShow();
         Cookies.set("/credit/goFinance/"+this.zfiId + "/", this.$route.fullPath)
         this.$router.push({ path: "/credit/goFinance/"+this.zfiId + "/" });
     }

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

@@ -245,8 +245,8 @@
                 </pdf-show>
             </el-dialog>
             <!--去融资-->
-            <el-dialog  :visible.sync="goShow" width="500px"  append-to-body :before-close = "cancelGo" center>
-                    <span>恭喜您成功签收一笔融信</span>
+            <el-dialog  :visible.sync="goShow" width="300px"  append-to-body :before-close = "cancelGo" center>
+                    <p>恭喜您成功签收一笔融信</p>
                     <div slot="footer" class="dialog-footer">
                         <el-button type="primary" @click="goFinance">去融资</el-button>
                         <el-button @click="cancelGo">取 消</el-button>

+ 13 - 11
front-vue/src/views/service/creditLine/creditLine.vue

@@ -539,9 +539,10 @@ export default {
       const zfpcrId = row.zfpcrId || this.ids;
       const zfiAmount = row.zfiAmount;
       const usableAmount = row.usableAmount;
+      const companyType = this.companyType;
       this.resetQuery();
-      Cookies.set("/creditLine/detailCreditLine/" + zfpcrId + '/' + zfiAmount + '/' + usableAmount + '/', this.$route.fullPath)
-      this.$router.push("/creditLine/detailCreditLine/" + zfpcrId + '/' + zfiAmount + '/' + usableAmount + '/',);
+      Cookies.set("/creditLine/detailCreditLine/" + zfpcrId + '/' + zfiAmount + '/' + usableAmount + '/' + companyType + '/', this.$route.fullPath)
+      this.$router.push("/creditLine/detailCreditLine/" + zfpcrId + '/' + zfiAmount + '/' + usableAmount + '/' + companyType + '/',);
     },
     /** 冻结/解冻按钮操作 */
     handleUpdate(row) {
@@ -615,15 +616,16 @@ export default {
     },
     /* 金额格式化 */
     moneyFormat(row, column, cellValue) {
-      if(cellValue){
-        cellValue += "";
-        if (!cellValue.includes(".")) cellValue += ".";
-        return cellValue
-          .replace(/(\d)(?=(\d{3})+\.)/g, function($0, $1) {
-            return $1 + ",";
-          })
-          .replace(/\.$/, "");
-      }
+        if(cellValue == null || cellValue== undefined || cellValue == ''){
+            cellValue = '0.00'
+        }
+        cellValue += '';
+        if (!cellValue.includes('.')) {
+            cellValue += '.00';
+        }
+        return cellValue.replace(/(\d)(?=(\d{3})+\.)/g, function ($0, $1) {
+            return $1 + ',';
+          }).replace(/\.$/, '');
     },
     /* 修改表格样式 */
     changeCellStyle(row, column, rowIndex, columnIndex) {

+ 23 - 20
front-vue/src/views/service/creditLine/detailCreditLine.vue

@@ -16,25 +16,25 @@
           </el-form-item>
         </el-col>
         <el-col :span="8">
-          <el-form-item label="融资产品:" prop="zfpcrProductId">
-            <el-select v-model="form.zfpcrProductId" style="width : 284px" clearable disabled>
+          <el-form-item label="授信企业名称:" prop="zfpcrCompanyId">
+            <el-select v-model="form.zfpcrCompanyId" style="width : 284px" clearable disabled>
               <el-option
-                v-for="(item,index) in financeProductList"
+                v-for="(item,index) in hxCompanyList"
                 :key="index"
-                :label="item.zfpName"
-                :value="item.zfpId"
+                :label="item.scyName"
+                :value="item.scyId"
               ></el-option>
             </el-select>
           </el-form-item>
         </el-col>
         <el-col :span="8">
-          <el-form-item label="授信企业名称:" prop="zfpcrCompanyId">
-            <el-select v-model="form.zfpcrCompanyId" style="width : 284px" clearable disabled>
+          <el-form-item label="融资产品:" prop="zfpcrProductId">
+            <el-select v-model="form.zfpcrProductId" style="width : 284px" clearable disabled>
               <el-option
-                v-for="(item,index) in hxCompanyList"
+                v-for="(item,index) in financeProductList"
                 :key="index"
-                :label="item.scyName"
-                :value="item.scyId"
+                :label="item.zfpName"
+                :value="item.zfpId"
               ></el-option>
             </el-select>
           </el-form-item>
@@ -111,7 +111,7 @@
           </el-form-item>
         </el-col>
         <el-col :span="8">
-          <el-form-item label="是否收取手续费:" prop="zfpcrCharge" label-width="113px">
+          <el-form-item label="是否收取手续费:" prop="zfpcrCharge" label-width="113px" v-if="this.companyType == '00'">
             <el-radio-group v-model="form.zfpcrCharge" size="medium" disabled>
               <el-radio-button  v-for="(dict,index) in chargeOptions" :key="index" :label="dict.dictValue" border>{{dict.dictLabel}}</el-radio-button>
             </el-radio-group>
@@ -120,14 +120,14 @@
       </el-row>
       <el-row>
         <el-col :span="8">
-          <el-form-item label="平台服务费收取费率:" prop="zfpcrChargeRate" label-width="139px" v-if="this.form.zfpcrCharge == '1'">
+          <el-form-item label="平台服务费收取费率:" prop="zfpcrChargeRate" label-width="139px" v-if="this.form.zfpcrCharge == '1' && this.companyType == '00'">
           <el-input v-model="form.zfpcrChargeRate" placeholder="请输入平台服务费收取费率" style="width:284px" readonly>
             <template slot="append">%</template>
           </el-input>
         </el-form-item>
         </el-col>
         <el-col :span="8">
-          <el-form-item label="核心企业还款账户账号:" prop="zfpcrAccount" label-width="142px">
+          <el-form-item label="核心企业还款账户账号:" prop="zfpcrAccount" label-width="142px" v-if="this.companyType == '00'">
             <el-autocomplete
               readonly
               style="width:286px"
@@ -139,7 +139,7 @@
           </el-form-item>
         </el-col>
         <el-col :span="8">
-          <el-form-item label="核心企业还款账户开户行:" prop="zfpcrAccountBank" label-width="142px">
+          <el-form-item label="核心企业还款账户开户行:" prop="zfpcrAccountBank" label-width="142px" v-if="this.companyType == '00'">
             <el-input v-model="form.zfpcrAccountBank" placeholder="请输入核心企业还款账户开户行" style="width:284px" maxlength="30" readonly>
             </el-input>
           </el-form-item>
@@ -147,7 +147,7 @@
       </el-row>
       <el-row>
         <el-col :span="8">
-          <el-form-item label="融资放款方式:" prop="zfpcrLoanType">
+          <el-form-item label="融资放款方式:" prop="zfpcrLoanType" v-if="this.companyType == '00'">
             <el-select v-model="form.zfpcrLoanType" placeholder="请选择状态" clearable style="width : 284px" clearable disabled>
               <el-option
                 v-for="dict in loanTypeOptions"
@@ -159,7 +159,7 @@
           </el-form-item>
         </el-col>
         <el-col :span="8">
-          <el-form-item label="记账簿托管方式:" prop="zfpcrBookkeepingType" label-width="113px">
+          <el-form-item label="记账簿托管方式:" prop="zfpcrBookkeepingType" label-width="113px" v-if="this.companyType == '00'">
             <el-select v-model="form.zfpcrBookkeepingType" placeholder="请选择状态" clearable style="width : 284px" clearable disabled>
               <el-option
                 v-for="dict in bookkeepingTypeOptions"
@@ -171,11 +171,11 @@
         </el-form-item>
         </el-col>
       </el-row>
-      <el-divider content-position="left">关联合同</el-divider>
+      <el-divider content-position="left" v-if="this.companyType == '00'">关联合同</el-divider >
       <el-form-item prop="zfqcrContractId" style="margin-left: 100px" >
         <!-- <el-button size="mini" type="primary" @click="openTicket">选择合同</el-button>
         <el-button size="mini" @click="deleteTicekt">清空全部</el-button> -->
-        <el-table :data="ticketList" style="width: 1100px">
+        <el-table :data="ticketList" style="width: 1100px" v-if="this.companyType == '00'">
           <el-table-column label="序号" type="index" width="50" align="center">
             <template slot-scope="scope">
               <span>{{ (queryParamsContract.pageNum - 1) * queryParamsContract.pageSize + scope.$index + 1}}</span>
@@ -283,6 +283,8 @@ export default {
   components: {},
   data() {
     return {
+      //企业类型
+      companyType: null,
       wordUrl: '',
       openWord: false,
       //金额展示
@@ -387,8 +389,8 @@ export default {
         zfpcrAmount: [
           { required: true, message: "授信额度不能为空", trigger: ["blur", "change"] },
           {
-             pattern: /^([0-9]{1,2}$)|(^[0-9]{1,2}\.[0-9]{1,2}$)|100$/,
-            message: "请输入正确的平台服务费收取费率",
+            pattern: /^[0-9][0-9]{0,8}$|^[1-9][0-9]{0,8}[.]\d{1,2}$/,
+            message: "请输入正确的额度",
             trigger: ["blur","change"],
           },
         ],
@@ -430,6 +432,7 @@ export default {
     const zfpcrId = this.$route.params && this.$route.params.zfpcrId;
     const zfiAmount = this.$route.params && this.$route.params.zfiAmount;
     const usableAmount = this.$route.params && this.$route.params.usableAmount;
+    this.companyType = this.$route.params && this.$route.params.companyType;
     var self =this;
     getCreditLine(zfpcrId).then((response) => {
       debugger

+ 10 - 9
front-vue/src/views/service/creditLine/supplierCreditLine.vue

@@ -526,15 +526,16 @@ export default {
     },
     /* 金额格式化 */
     moneyFormat(row, column, cellValue) {
-      if(cellValue){
-        cellValue += "";
-        if (!cellValue.includes(".")) cellValue += ".";
-        return cellValue
-          .replace(/(\d)(?=(\d{3})+\.)/g, function($0, $1) {
-            return $1 + ",";
-          })
-          .replace(/\.$/, "");
-      }
+        if(cellValue == null || cellValue== undefined || cellValue == ''){
+            cellValue = '0.00'
+        }
+        cellValue += '';
+        if (!cellValue.includes('.')) {
+            cellValue += '.00';
+        }
+        return cellValue.replace(/(\d)(?=(\d{3})+\.)/g, function ($0, $1) {
+            return $1 + ',';
+          }).replace(/\.$/, '');
     },
   }
 };

+ 11 - 10
front-vue/src/views/service/financeRecord/financeRecord.vue

@@ -1107,16 +1107,17 @@ export default {
         },
         /* 金额格式化 */
         moneyFormat(row, column, cellValue) {
-            if (cellValue) {
-                cellValue += "";
-                if (!cellValue.includes(".")) cellValue += ".";
-                return cellValue
-                    .replace(/(\d)(?=(\d{3})+\.)/g, function ($0, $1) {
-                        return $1 + ",";
-                    })
-                    .replace(/\.$/, "");
-            }
-        },
+        if(cellValue == null || cellValue== undefined || cellValue == ''){
+            cellValue = '0.00'
+        }
+        cellValue += '';
+        if (!cellValue.includes('.')) {
+            cellValue += '.00';
+        }
+        return cellValue.replace(/(\d)(?=(\d{3})+\.)/g, function ($0, $1) {
+            return $1 + ',';
+          }).replace(/\.$/, '');
+    },
         //获取当前客户是否之前设置过列展示隐藏
         columnQuery() {
             //获取页面路径