<template>
|
<div class="comm-page">
|
<div class="form-content">
|
<FormList
|
:info="formInfo"
|
:isShowDetail="isShowDetail"
|
@handleClick="isShowDetail = !isShowDetail"
|
@updateValue="updateValue"
|
@onSubmit="onSubmit"
|
@setValueInfo="setValueInfo"
|
></FormList>
|
</div>
|
|
<p class="export-excle">
|
<el-button
|
size="small"
|
type="primary"
|
@click="autoClaimTask"
|
icon="iconfont icon-xitongfenpeirenwu"
|
class="el-button-primary"
|
v-if="phaseFlag!=30&&phaseFlag!=40"
|
>系统分配任务</el-button>
|
<!-- 下面三个按钮只有在财务放款阶段才有 -->
|
<el-button
|
size="small"
|
style="margin-left:50px"
|
plain
|
@click="systemPutout"
|
class="el-button-primary"
|
v-if="phaseFlag==14"
|
>系统放款</el-button>
|
<el-button
|
size="small"
|
style="margin-left:20px"
|
plain
|
@click="artificialPutoutBatch"
|
class="el-button-primary"
|
v-if="phaseFlag==14"
|
>人工放款</el-button>
|
<el-button
|
size="small"
|
style="margin-left:20px"
|
plain
|
@click="putoutTurnArtificial"
|
class="el-button-primary"
|
v-if="phaseFlag==14"
|
>转人工放款</el-button>
|
<el-button
|
size="small"
|
style="margin-left:20px"
|
plain
|
@click="viewAccounts"
|
class="el-button-primary"
|
v-if="phaseFlag==14"
|
>查看账户信息</el-button>
|
<el-button
|
size="small"
|
style="margin-left:20px"
|
plain
|
@click="exportNetBank"
|
class="el-button-primary"
|
v-if="phaseFlag==14"
|
>导出网银指令</el-button>
|
<el-button
|
size="small"
|
style="margin-left:20px"
|
plain
|
@click="printPayApply"
|
class="el-button-primary"
|
v-if="phaseFlag==14"
|
>打印付款申请书</el-button>
|
<el-button
|
size="small"
|
style="margin-left:20px"
|
plain
|
@click="onCapitalLoanFailure"
|
class="el-button-primary"
|
v-if="phaseFlag==14"
|
>资方放款失败处理</el-button>
|
</p>
|
|
<div class="list-content">
|
<TableList
|
:pageInfo="pageInfo"
|
@doAction="doAction"
|
@handleCurrentChange="handleCurrentChange"
|
@handleSizeChange="handleSizeChange"
|
@handleSelectionChange="handleSelectionChange"
|
:isAutoIndex="true && phaseFlag != 14"
|
:isMultipleSelect="phaseFlag == 14"
|
:isPaddingRight="false"
|
:activeIndex="activeIndex"
|
:list="records"
|
:header="tableHeader"
|
:loading="loading"
|
></TableList>
|
</div>
|
|
<el-dialog
|
:visible.sync="dialogTableVisible"
|
custom-class="comm-dialog"
|
:modal-append-to-body="false"
|
:close-on-click-modal='false'
|
center
|
>
|
<TrialRepaymentPlan :serialNo="serialNo"></TrialRepaymentPlan>
|
<span slot="footer" class="dialog-footer">
|
<el-button type="primary" @click="dialogTableVisible = false">关闭</el-button>
|
</span>
|
</el-dialog>
|
|
<el-dialog
|
v-if="dialogDockerVisible"
|
:visible.sync="dialogDockerVisible"
|
custom-class="comm-dialog"
|
:modal-append-to-body="false"
|
:close-on-click-modal='false'
|
center
|
>
|
<Docker :serialNo="serialNo" :customerid='customerid' :customerName='customerName' :reditcode='reditcode'></Docker>
|
<span slot="footer" class="dialog-footer">
|
<el-button type="primary" @click="dialogDockerVisible = false">关闭</el-button>
|
</span>
|
</el-dialog>
|
|
<el-dialog
|
title="面签预约信息"
|
:visible.sync="dialogAppointment"
|
custom-class="comm-dialog"
|
:modal-append-to-body="false"
|
:close-on-click-modal='false'
|
center
|
>
|
<Appointment :serialNo="serialNo"></Appointment>
|
<span slot="footer" class="dialog-footer">
|
<el-button type="primary" @click="dialogAppointment = false">关闭</el-button>
|
</span>
|
</el-dialog>
|
|
<el-dialog
|
:title="loanStatus"
|
:visible.sync="dialogLoan"
|
custom-class="comm-dialog"
|
:modal-append-to-body="false"
|
:close-on-click-modal='false'
|
:destroy-on-close="true"
|
center
|
>
|
<Loan
|
:loanStatus="loanStatus"
|
:putoutCheckInfoList="putoutCheckInfoList"
|
@close="dialogLoan = false;init()"
|
></Loan>
|
</el-dialog>
|
|
<el-dialog
|
:title="loanStatus"
|
:visible.sync="dialogRefund"
|
custom-class="comm-dialog"
|
:modal-append-to-body="false"
|
:close-on-click-modal='false'
|
:destroy-on-close="true"
|
center
|
>
|
<Refund
|
v-if="dialogRefund"
|
:refunds='refunds'
|
@close="dialogRefund = false;init()"
|
></Refund>
|
</el-dialog>
|
|
<el-dialog
|
title="支付公司备付金账户信息"
|
:visible.sync="dialogAccounts"
|
custom-class="comm-dialog"
|
:modal-append-to-body="false"
|
:close-on-click-modal='false'
|
:destroy-on-close="true"
|
center
|
>
|
<PayCompanys
|
v-if="dialogAccounts"
|
:accounts='accounts'
|
@close="dialogAccounts = false"
|
></PayCompanys>
|
</el-dialog>
|
|
<el-dialog
|
:title="loanStatus"
|
:visible.sync="dialogFailure"
|
custom-class="comm-dialog"
|
:modal-append-to-body="false"
|
:close-on-click-modal='false'
|
:destroy-on-close="true"
|
center
|
>
|
<CapitalLoanFailure
|
:loanStatus="loanStatus"
|
:failList="failList"
|
:putoutCheckInfoList="putoutCheckInfoList"
|
@close="dialogFailure = false;init()"
|
></CapitalLoanFailure>
|
</el-dialog>
|
</div>
|
</template>
|
<script>
|
/**
|
* 公共页面
|
*/
|
import TableList from "./TableList";
|
import FormList from "./FormList";
|
import TrialRepaymentPlan from "./TrialRepaymentPlan";
|
import Appointment from "./Appointment";
|
import Loan from "./Loan";
|
import Refund from "./Refund";
|
import PayCompanys from "./PayCompanys";
|
import Docker from "./Docker";
|
import CapitalLoanFailure from "./CapitalLoanFailure";
|
|
import { comfirm } from '@comprehensive/utils/comm'
|
import {
|
qryProdList,
|
qryDimensionList,
|
qryFlowPhaseList,
|
getAllCityAreaList,
|
qryApplyFlowList,
|
autoClaimTask,
|
claimTask,
|
routePutoutFundunitno,
|
returnTaskPool,
|
getDictionaryList,
|
putoutCheck,
|
qryDictionaryList,
|
queryPayAcctInfo,
|
claimTaskForFactoring,
|
cancelRefactoringApply,
|
qryZBDEntAlterList,
|
newZbdEntAlter,
|
cancelZBDAlter,
|
claimZBDAlterTask,
|
cancelApplyLoan,
|
putoutFailList
|
} from "@comprehensive/serve/public";
|
|
export default {
|
components: {
|
FormList,
|
TableList,
|
TrialRepaymentPlan,
|
Appointment,
|
Refund,
|
Loan,
|
PayCompanys,
|
Docker,
|
CapitalLoanFailure
|
},
|
props: {
|
formInfo: {
|
type: Array,
|
default: () => []
|
},
|
tableHeader: {
|
type: Array,
|
default: () => []
|
},
|
|
// 查询标识 02:城市;03:区县
|
queryFlag: {
|
type: String,
|
default: "02"
|
},
|
|
// 查询阶段标识:
|
// 01:预审批申请;
|
// 02:预审复核(内部渠道审批);
|
// 03:贷款申请;
|
// 04:自动化预审批;
|
// 05:客户申请复核;
|
// 06:地区金融审核(地区预审);
|
// 07:征信录入;
|
// 08:初审;
|
// 09:复审;
|
// 10:终审;
|
// 11:凭证审核;
|
// 12:预收息费;
|
// 13:面签;
|
// 14:财务放款;
|
// 15:登记赎楼信息;
|
// 16:登记办证信息;
|
// 17:办理抵押;
|
// 18:凭证补传;
|
// 19: 放款成功;
|
// 20: 授信成功;
|
// 21:申请拒绝;
|
// 22:取消申请;
|
// 23:资方授信(抵押);
|
// 24:抵押审核;
|
// 25:赎楼业务确认;
|
// 26:对公或赎楼回款;
|
// 27:赎楼贷息费结算;
|
// 28:投标凭证回传;
|
// 29:回款凭证回传;
|
// 30:授信企业信息
|
// 32: 应收账款融资登记撤销
|
// 33: 应收账款债务人支付结算
|
// 34: 再保理申请
|
// 35: 再保理回款
|
// 36:赎楼退款审核
|
// 37:赎楼退款出账
|
// 38:企业垫资凭证补传
|
// 39:企业垫资凭证审核
|
phaseFlag: {
|
type: String,
|
default: ""
|
}
|
},
|
data() {
|
return {
|
// 表单结果数据
|
putoutCheckInfoList: [],
|
accounts: [],
|
failList: [],
|
valueInfo: {},
|
refunds: {},
|
records: [],
|
pageInfo: {
|
currentPage: 1,
|
pageSize: 10,
|
total: 0
|
},
|
isShowDetail: false,// 是否显示所有表单项
|
loading: false,
|
dialogTableVisible: false,
|
dialogAppointment: false,
|
dialogLoan: false,
|
dialogRefund: false,
|
dialogAccounts: false,
|
dialogDockerVisible: false,
|
dialogFailure: false,
|
loanStatus: "",
|
serialNo: "",
|
customerid: "",
|
customerName: "",
|
reditcode: "",
|
};
|
},
|
activated() {
|
this.init();
|
},
|
computed: {
|
activeIndex(){
|
const arr = []
|
this.records.forEach((item,i) => {
|
this.putoutCheckInfoList.forEach(val => {
|
if(item.serialNo == val.serialNo){
|
arr.push(i)
|
}
|
});
|
});
|
return arr
|
}
|
},
|
methods: {
|
// 页面初始化处理
|
init() {
|
const { formInfo, phaseFlag } = this;
|
|
if (formInfo.some(({ name }) => name === "businessCity")) {
|
this.getAllCityAreaList();
|
}
|
if (formInfo.some(({ name }) => name === "phaseNo")) {
|
this.qryFlowPhaseList();
|
}
|
if (formInfo.some(({ name }) => name === "productDimension")) {
|
this.qryDimensionList();
|
}
|
if (formInfo.some(({ name }) => name === "productid")) {
|
this.qryProdList();
|
}
|
if (formInfo.some(({ name }) => name === "manualPutOutFlag")) {
|
this.getManualPutOutFlag();
|
}
|
if (formInfo.some(({ name }) => name === "autoPutOutFlag")) {
|
this.getAutoPutOutFlag();
|
}
|
if (formInfo.some(({ name }) => name === "printVoucherFlag")) {
|
this.getPrintVoucherFlag();
|
}
|
if (formInfo.some(({ name }) => name === "ebankCommandFlag")) {
|
this.getEbankCommandFlag();
|
}
|
if (formInfo.some(({ name }) => name === "entadvancemoneystatus")) {
|
this.getEntAdvanceMoneyStatus();
|
}
|
if (formInfo.some(({ name }) => name === "isentadvancemoney" || name === "isexceed")) {
|
this.getDictionaryList();
|
}
|
if (formInfo.some(({ name }) => name === "flowstate")) {
|
this.getFlowstateList();
|
}
|
|
if(phaseFlag == '30' || phaseFlag == '40'){
|
// 招标贷企业信息修改和审批列表查询
|
this.qryZBDEntAlterList()
|
}else{
|
this.qryApplyFlowList();
|
}
|
|
},
|
|
// 打印付款申请书
|
printPayApply(){
|
if (!this.putoutCheckInfoList.length) {
|
this.$message.warning("请选择打印付款申请书的数据");
|
return;
|
}
|
this.loanStatus = "导出付款申请书信息确认";
|
this.dialogLoan = true;
|
},
|
|
// 资方放款失败处理
|
async onCapitalLoanFailure() {
|
if (!this.putoutCheckInfoList.length) {
|
this.$message.warning("请选择需要处理的数据");
|
return;
|
}
|
if (this.putoutCheckInfoList.length !== 1) {
|
this.$message.warning("只可选择一条数据");
|
return;
|
}
|
|
const { result } = await putoutFailList({
|
serialNo: this.putoutCheckInfoList[0].serialNo
|
})
|
this.loanStatus = "确认资方放款失败处理";
|
this.dialogFailure = true;
|
this.failList = result
|
},
|
|
// 查看账户信息
|
async viewAccounts(){
|
this.dialogAccounts = true
|
const { result } = await queryPayAcctInfo()
|
this.accounts = result
|
},
|
|
// 系统放款
|
systemPutout() {
|
if (!this.putoutCheckInfoList.length) {
|
this.$message.warning("请选择需要系统放款的数据");
|
return;
|
}
|
putoutCheck({
|
checkType: "01",
|
putoutCheckInfoList: this.putoutCheckInfoList
|
}).then(res => {
|
if (res.code == "00") {
|
this.loanStatus = "系统放款信息确认";
|
this.dialogLoan = true;
|
}
|
});
|
},
|
|
// 转人工放款
|
putoutTurnArtificial() {
|
if (!this.putoutCheckInfoList.length) {
|
this.$message.warning("请选择需要转人工放款的数据");
|
return;
|
}
|
putoutCheck({
|
checkType: "02",
|
putoutCheckInfoList: this.putoutCheckInfoList
|
}).then(res => {
|
if (res.code == "00") {
|
this.loanStatus = "转人工放款信息确认";
|
this.dialogLoan = true;
|
}
|
});
|
},
|
|
// 人工放款
|
artificialPutoutBatch() {
|
if (!this.putoutCheckInfoList.length) {
|
this.$message.warning("请选择需要人工放款的数据");
|
return;
|
}
|
putoutCheck({
|
checkType: "03",
|
putoutCheckInfoList: this.putoutCheckInfoList
|
}).then(res => {
|
if (res.code == "00") {
|
this.loanStatus = "线下人工放款信息确认";
|
this.dialogLoan = true;
|
}
|
});
|
},
|
|
// 导出网银指令信息确认
|
exportNetBank(){
|
if (!this.putoutCheckInfoList.length) {
|
this.$message.warning("请选择导出网银指令的数据");
|
return;
|
}
|
this.loanStatus = "导出网银指令信息确认";
|
this.dialogLoan = true;
|
},
|
|
// 财务放款阶段需要获取列表选中的数据
|
handleSelectionChange(array) {
|
this.putoutCheckInfoList = array;
|
},
|
|
// 设置表单结果数据
|
setValueInfo(info = {}) {
|
this.valueInfo = info;
|
},
|
|
// 产品名称下拉列表
|
async qryProdList() {
|
const res = await qryProdList({ productTypeNo: "" });
|
const { result } = res;
|
this.setOrGetFormInfo("productid", { options: result });
|
},
|
|
// 人工放款标志
|
async getManualPutOutFlag() {
|
const res = await getDictionaryList({ codeNo: "YesNo" });
|
const { result } = res;
|
this.setOrGetFormInfo("manualPutOutFlag", {
|
options: [{ itemname: "全部", itemno: "" }, ...result]
|
});
|
},
|
|
// 放款凭证标志
|
async getPrintVoucherFlag() {
|
const res = await getDictionaryList({ codeNo: "VoucherFlag" });
|
const { result } = res;
|
this.setOrGetFormInfo("printVoucherFlag", {
|
options: result
|
});
|
},
|
|
// 系统放款状态
|
async getAutoPutOutFlag() {
|
const res = await getDictionaryList({ codeNo: "AutoPutOutFlag" });
|
const { result } = res;
|
this.setOrGetFormInfo("autoPutOutFlag", {
|
options: result
|
});
|
},
|
|
// 网银指令标志
|
async getEbankCommandFlag() {
|
const res = await getDictionaryList({ codeNo: "VoucherFlag" });
|
const { result } = res;
|
this.setOrGetFormInfo("ebankCommandFlag", {
|
options: [{ itemname: "全部", itemno: "" }, ...result]
|
});
|
},
|
|
// 产品维度下拉列表
|
async qryDimensionList() {
|
const { valueInfo } = this;
|
let { productid = "" } = valueInfo;
|
const res = await qryDimensionList({ productid });
|
const { result } = res;
|
this.setOrGetFormInfo("productDimension", { options: result });
|
},
|
|
// 当前流程阶段下拉列表
|
async qryFlowPhaseList() {
|
const {phaseFlag} = this
|
const res = await qryFlowPhaseList({phaseFlag});
|
const { result } = res;
|
this.setOrGetFormInfo("phaseNo", { options: result });
|
},
|
|
// 是否下拉列表
|
async getDictionaryList() {
|
const res = await getDictionaryList({ codeNo: 'YesNo' });
|
const { result } = res;
|
this.setOrGetFormInfo("isentadvancemoney", { options: result });
|
this.setOrGetFormInfo("isexceed", { options: result });
|
},
|
|
// 状态
|
async getFlowstateList() {
|
const res = await getDictionaryList({ codeNo: "ZBDEntAlterState" });
|
const { result } = res;
|
this.setOrGetFormInfo("flowstate", { options: result });
|
},
|
|
// 垫资补传凭证状态
|
async getEntAdvanceMoneyStatus() {
|
const res = await getDictionaryList({ codeNo: "entAdvanceMoneyStatus" });
|
const { result } = res;
|
this.setOrGetFormInfo("entadvancemoneystatus", { options: result });
|
},
|
|
// 业务城市下拉列表
|
async getAllCityAreaList() {
|
const { queryFlag, formInfo } = this;
|
const res = await getAllCityAreaList({ queryFlag });
|
const { result } = res;
|
this.setOrGetFormInfo("businessCity", { options: result });
|
|
if (formInfo.some(({ name }) => name === "signedCity")) {
|
this.setOrGetFormInfo("signedCity", { options: result });
|
}
|
},
|
|
// 系统分配任务
|
async autoClaimTask() {
|
const { phaseFlag } = this;
|
try {
|
const res = await autoClaimTask({ phaseFlag });
|
const { result } = res;
|
this.toEdit(result);
|
} catch (e) {
|
console.log(e);
|
}
|
},
|
|
// 跳转到详情页
|
toDetail(result) {
|
const {
|
serialNo,
|
flowno,
|
customerid: customerID,
|
objecttype: objectType,
|
occurtype,
|
alterobjectno
|
} = result;
|
|
let params = `${serialNo}?occurType=${occurtype}&flowno=${flowno}&objectType=${objectType}&customerID=${customerID}`
|
if(alterobjectno){
|
params = `${params}&alterobjectno=${alterobjectno}`
|
}
|
this.$router.push(
|
`/comprehensiveTransaction/loanDetail/${params}`
|
);
|
},
|
|
// 获取当前数据列表
|
async qryApplyFlowList() {
|
this.loading = true;
|
let { valueInfo, pageInfo, phaseFlag, queryFlag } = this;
|
const res = await qryApplyFlowList({
|
...valueInfo,
|
phaseFlag,
|
queryFlag,
|
...pageInfo
|
});
|
const { records = [], total } = res.result;
|
this.loading = false;
|
this.records = records.reduce((pre, curr) => {
|
// 贷款期限处理
|
let {
|
trialFlag,
|
detailFlag,
|
immediateFlag,
|
continueFlag,
|
appointFlag,
|
updateFlag,
|
supplyFlag,
|
drawbackFlag,
|
resetFlag,
|
returnPoolFlag,
|
cancelFlag,
|
termUnit,
|
businessTermMonth,
|
businessTermDay,
|
amountloan,
|
businesssum
|
} = curr;
|
let arr = [];
|
let businessTermDescription = "";
|
|
if (amountloan !== "" && amountloan !== "0") {
|
businesssum = amountloan;
|
}
|
if (immediateFlag === "1") {
|
if(phaseFlag == '34'){
|
// 如果阶段是再保理申请,立即处理更换成申请
|
arr.push({ label: "申请", id: 3 });
|
}else{
|
arr.push({ label: "立即处理", id: 3 });
|
}
|
}
|
if (continueFlag === "1") {
|
if(phaseFlag == '34'){
|
// 如果阶段是再保理申请,继续处理更换成修改
|
arr.push({ label: "修改", id: 5 });
|
}else{
|
arr.push({ label: "继续处理", id: 4 });
|
}
|
}
|
if (appointFlag === "1") {
|
arr.push({ label: "预约", id: 2 });
|
}
|
if (trialFlag === "1") {
|
arr.push({ label: "还款试算", id: 0 });
|
}
|
if (detailFlag === "1") {
|
arr.push({ label: "详情", id: 1 });
|
}
|
if (updateFlag === "1") {
|
arr.push({ label: "修改", id: 5 });
|
}
|
if (supplyFlag === "1") {
|
arr.push({ label: "补充资料", id: 6 });
|
}
|
if (cancelFlag === "1") {
|
arr.push({ label: "取消申请", id: 8 });
|
}
|
if (resetFlag === "1") {
|
arr.push({ label: "重新申请", id: 7 });
|
}
|
if (drawbackFlag === "1") {
|
arr.push({ label: "退款", id: 9 });
|
}
|
// if (cancelFlag === '1') {
|
// arr.push({ label: '取消申请', id: 9 })
|
// }
|
|
if (returnPoolFlag === "1") {
|
arr.push({ label: "退回任务池", id: 10 });
|
}
|
let sortButtons = [
|
"立即处理",
|
"继续处理",
|
"预约",
|
"还款试算",
|
"修改",
|
"申请",
|
"详情",
|
"退回任务池",
|
"取消申请",
|
"退款"
|
];
|
|
if (phaseFlag === "01") {
|
sortButtons = ["修改", "详情", "取消申请", "重新申请", "退回任务池"];
|
}
|
|
arr = this.getSortButtons(sortButtons, arr);
|
|
// 贷款期限描述处理
|
if (termUnit === "M" && businessTermMonth) {
|
businessTermDescription = `${businessTermMonth}月`;
|
}
|
|
if (termUnit === "D" && businessTermDay) {
|
businessTermDescription = `${businessTermDay}天`;
|
}
|
|
pre.push({
|
...curr,
|
businessTermDescription,
|
buttons: [...arr],
|
businesssum
|
});
|
|
return pre;
|
}, []);
|
|
this.pageInfo = {
|
...pageInfo,
|
total
|
};
|
},
|
|
// 招标贷企业信息修改和审批查询
|
async qryZBDEntAlterList(){
|
this.loading = true;
|
let { valueInfo, pageInfo, phaseFlag, queryFlag } = this;
|
const res = await qryZBDEntAlterList({
|
...valueInfo,
|
phaseFlag,
|
queryFlag,
|
...pageInfo
|
})
|
const { records = [], total } = res.result;
|
this.loading = false;
|
this.records = records.reduce((pre, curr) => {
|
// 贷款期限处理
|
let {
|
immediateFlag,
|
continueFlag,
|
cancelFlag
|
} = curr;
|
let arr = [];
|
if (window.parent._server_queryZBDEntAlterTabTree || window.parent._server_queryTabTree) {
|
arr.push({ label: "详情", id:1 });
|
}
|
if (immediateFlag === "1") {
|
arr.push({ label: "立即处理", id:14 });
|
}
|
if (continueFlag === "1") {
|
arr.push({ label: "继续处理", id:15 });
|
}
|
if (phaseFlag == '30' && window.parent._server_queryApplyTabTree) {
|
arr.push({ label: "修改", id: 5 });
|
}
|
if (phaseFlag == '30' && window.parent._server_queryApplyZBDEntAlterTabTree) {
|
arr.push({ label: "变更企业信息", id:11 });
|
}
|
if (phaseFlag == '30' && window.parent._server_qryPickUpPeopleList) {
|
arr.push({ label: "修改业务对接人", id:12 });
|
}
|
if (cancelFlag === '1') {
|
arr.push({ label: "取消申请", id:13 });
|
}
|
let sortButtons = [
|
"修改",
|
"立即处理",
|
"继续处理",
|
'取消申请',
|
"修改业务对接人",
|
"变更企业信息",
|
"详情",
|
];
|
|
arr = this.getSortButtons(sortButtons, arr);
|
|
pre.push({
|
...curr,
|
buttons: [...arr],
|
});
|
|
return pre;
|
}, []);
|
|
this.pageInfo = {
|
...pageInfo,
|
total
|
};
|
},
|
|
// 按钮顺序排序
|
getSortButtons(sortButtons, arr) {
|
return sortButtons.reduce((pre, curr) => {
|
const item = arr.find(({ label }) => label === curr);
|
if (item) {
|
pre.push({ ...item });
|
}
|
return pre;
|
}, []);
|
},
|
|
// 更新表单数据或查找某项数据
|
setOrGetFormInfo(nameKey, newInfo) {
|
this.$emit("setOrGetFormInfo", nameKey, newInfo);
|
},
|
|
// 更新数据
|
updateValue(value, item) {
|
let { name } = item;
|
this.setOrGetFormInfo(name, { value });
|
if (name === "productid") {
|
this.qryDimensionList();
|
}
|
},
|
|
// 查询操作
|
onSubmit() {
|
const { phaseFlag } = this;
|
this.pageInfo.currentPage = 1;
|
if(phaseFlag == '30' || phaseFlag == '40'){
|
// 招标贷企业信息修改和审批列表查询
|
this.qryZBDEntAlterList()
|
}else{
|
this.qryApplyFlowList();
|
}
|
},
|
|
// 表单事件回调
|
async doAction(name, item, { id, label }) {
|
if (name === "lastAction") {
|
const { phaseFlag } = this;
|
const { objectType, serialNo, customerid, customerName, reditcode, flowstate, alterobjectno } = item;
|
const detailInfo = { ...item, objecttype: objectType };
|
|
// 试算
|
if (id === 0) {
|
const { serialNo } = item;
|
this.serialNo = serialNo;
|
this.dialogTableVisible = true;
|
}
|
|
// 查看详情
|
if (id === 1) {
|
if(phaseFlag == '40'){
|
detailInfo.flowno = detailInfo.alterobjecttype
|
}
|
this.toDetail(detailInfo);
|
}
|
|
// 预约
|
if (id === 2) {
|
const { serialNo } = item;
|
this.serialNo = serialNo;
|
this.dialogAppointment = true;
|
}
|
|
// 立即处理
|
if (id === 3) {
|
this.claimTask(detailInfo);
|
}
|
|
// 继续处理
|
if (id === 4) {
|
this.toEdit(detailInfo);
|
}
|
|
// 修改
|
if (id === 5) {
|
if( flowstate == '0010' || flowstate == '0020' ){
|
this.$message.warning('当前申请单存在审批中的企业信息修改记录,请完成审批后在修改!');
|
}else{
|
this.toEdit(detailInfo);
|
}
|
}
|
|
// 取消申请
|
if (id === 8) {
|
this.cancelApplyLoan(detailInfo, customerName);
|
}
|
|
// 退款
|
if(id === 9){
|
this.loanStatus = "线下退款信息确认";
|
this.dialogRefund = true;
|
this.refunds = item
|
}
|
|
// 退回任务池
|
if (id === 10) {
|
this.returnTaskPool(detailInfo);
|
}
|
|
// 招标贷企业的变更页面
|
if(id === 11){
|
comfirm('变更申请确认',`请确认是否变更${customerName}的申请信息!`,async ()=>{
|
const res = await newZbdEntAlter({
|
serialNo: detailInfo.serialNo
|
})
|
const { result } = res
|
if(res.code == '00'){
|
detailInfo.ftSerialNo = result.ftserialno
|
detailInfo.alterobjectno = result.alterobjectno
|
detailInfo.alterobjecttype = result.alterobjecttype
|
detailInfo.flowno = result.alterobjecttype
|
this.toEdit(detailInfo)
|
}
|
})
|
}
|
|
// 招标贷企业修改对接人
|
if(id === 12){
|
if( flowstate == '0010' || flowstate == '0020' ){
|
this.$message.warning('当前申请单存在审批中的企业信息修改记录,请完成审批后在修改!');
|
}else{
|
this.serialNo = serialNo;
|
this.customerid = customerid;
|
this.customerName = customerName;
|
this.reditcode = reditcode;
|
this.dialogDockerVisible = true;
|
}
|
}
|
|
// 招标贷企业取消申请
|
if(id === 13){
|
comfirm('取消申请确认',`请确认是否取消${customerName}的申请信息!`,async ()=>{
|
this.loading = true
|
const { code } = await cancelZBDAlter({ alterobjectno })
|
if(code == '00'){
|
this.$message.success('取消申请成功')
|
this.init()
|
}
|
this.loading = false
|
})
|
}
|
|
// 招标贷企业立即处理
|
if(id === 14){
|
this.loading = true
|
const { code } = await claimZBDAlterTask({ objectNo : alterobjectno })
|
this.loading = false
|
if(code == '00'){
|
detailInfo.flowno = detailInfo.alterobjecttype
|
this.toEdit(detailInfo);
|
}
|
}
|
|
// 招标贷企业继续处理
|
if(id === 15){
|
detailInfo.flowno = detailInfo.alterobjecttype
|
this.toEdit(detailInfo);
|
}
|
}
|
},
|
|
// 跳转到编辑页
|
toEdit(detailInfo) {
|
let { objecttype = "", phaseno = "", productid = "" } = detailInfo;
|
|
this.$store.commit("SET_applyInfo", {
|
objectType: detailInfo.objectType || objecttype,
|
phaseNo: detailInfo.phaseNo || phaseno,
|
productID: detailInfo.productID || productid,
|
...detailInfo
|
});
|
this.$router.push("/loanApplyEdit");
|
},
|
|
// 有审批意见接口
|
claimTaskForFactoring(phasechoice,detailInfo){
|
claimTaskForFactoring({
|
'objectNo': detailInfo.serialNo,
|
'phasechoice': phasechoice,
|
}).then(res => {
|
this.loading = false
|
if(res.result.serialno){
|
detailInfo.ftSerialNo = res.result.serialno
|
}
|
this.toEdit(detailInfo);
|
})
|
.catch(reson => {
|
this.loading = false
|
this.qryApplyFlowList();
|
});
|
},
|
|
// 取消申请
|
async cancelApplyLoan(detailInfo, customerName){
|
comfirm('取消申请确认',`请确认是否取消${customerName}的申请信息!`,async ()=>{
|
this.loading = true
|
const { code } = await cancelApplyLoan({ objectNo: detailInfo.serialNo, taskNo: detailInfo.ftSerialNo })
|
if(code == '00'){
|
this.$message.success('取消申请成功')
|
this.init()
|
}
|
this.loading = false
|
})
|
},
|
|
// 立即处理
|
async claimTask(detailInfo) {
|
// 应收账款债务人支付结算,再保理申请和保理回款阶段调用新接口
|
const { phaseFlag } = this
|
this.loading = true
|
if(phaseFlag == '33'){
|
this.claimTaskForFactoring('26',detailInfo)
|
}else if(phaseFlag == '34'){
|
this.claimTaskForFactoring('25',detailInfo)
|
}else if(phaseFlag == '35'){
|
this.claimTaskForFactoring('27',detailInfo)
|
}else{
|
if(phaseFlag == '13') {
|
// 贷款面签阶段 - 面签领单前先查询有无资金方
|
try {
|
await routePutoutFundunitno({serialNo: detailInfo.serialNo})
|
} catch (error) {
|
this.loading = false
|
return
|
}
|
}
|
claimTask({
|
objectNo: detailInfo.serialNo
|
}).then(res => {
|
this.loading = false
|
this.toEdit(detailInfo);
|
})
|
.catch(reson => {
|
this.loading = false
|
this.qryApplyFlowList();
|
});
|
}
|
},
|
|
// 退回任务池
|
returnTaskPool(detailInfo) {
|
comfirm('提示','请确认是否退回任务池!',()=>{
|
this.toReturnTaskPool(detailInfo);
|
})
|
},
|
|
// 退回任务池
|
async toReturnTaskPool(detailInfo) {
|
await returnTaskPool({
|
objectNo: detailInfo.serialNo,
|
objectType: detailInfo.objecttype
|
});
|
this.$message({
|
type: "info",
|
message: "已退回任务池"
|
});
|
setTimeout(() => {
|
this.pageInfo.currentPage = 1;
|
this.qryApplyFlowList();
|
}, 1000);
|
},
|
|
// 修改翻页条数
|
handleSizeChange(val) {
|
const { phaseFlag } = this;
|
this.pageInfo.pageSize = val;
|
if(phaseFlag == '30' || phaseFlag == '40'){
|
// 招标贷企业信息修改和审批列表查询
|
this.qryZBDEntAlterList()
|
}else{
|
this.qryApplyFlowList();
|
}
|
},
|
|
// 修改翻页数
|
handleCurrentChange(val) {
|
const { phaseFlag } = this;
|
this.pageInfo.currentPage = val;
|
if(phaseFlag == '30' || phaseFlag == '40'){
|
// 招标贷企业信息修改和审批列表查询
|
this.qryZBDEntAlterList()
|
}else{
|
this.qryApplyFlowList();
|
}
|
}
|
}
|
};
|
</script>
|
<style lang="postcss" scoped>
|
.comm-page {
|
& .list-content {
|
font-size: 14px;
|
}
|
& .export-excle {
|
margin: 0 20px 30px 0;
|
& .el-button-primary {
|
font-size: 14px;
|
padding: 9px 12px;
|
}
|
}
|
& .empty-section {
|
height: 50px;
|
}
|
& >>> .comm-dialog {
|
width: auto;
|
max-width: calc(100% - 180px);
|
min-width: 850px;
|
max-height: 100%;
|
overflow: hidden;
|
margin: 0 !important;
|
position: absolute;
|
left: 50%;
|
top: 50%;
|
transform: translate(-50%,-50%);
|
& .el-dialog__body {
|
padding: 20px;
|
}
|
& .el-dialog__header {
|
padding: 20px 0 0;
|
}
|
& .el-dialog__footer {
|
padding: 0 0 20px;
|
& .el-button {
|
width: 120px;
|
font-size: 14px;
|
line-height: 20px;
|
padding: 5px 0;
|
}
|
}
|
}
|
}
|
</style>
|