/* * @Author: Pengjiantian * @Date: 2020-02-28 14:50:28 * @Last Modified by: Pengjiantian * @Last Modified time: 2020-03-04 15:29:11 */ /** * 管控额度修改查询 */ import ApiModel from "@/utils/core/apiModel"; // 基础额度 申请阶段 表单信息 const formList = [ { type: "input", label: "客户编号", value: "", name: "customerId", attrs: ["readonly"] }, { type: "input", label: "客户名称", value: "", name: "customerName", attrs: ["readonly"] }, { type: "input", label: "证件类型", value: "", name: "certTypeDesc", attrs: ["readonly"] }, { type: "input", label: "证件号码", value: "", name: "certId", attrs: ["readonly"] }, { type: "input", label: "额度类型", value: "", name: "quotaTypeDesc", attrs: ["readonly"] }, { type: "input", label: "产品", value: "", name: "productName", attrs: ["readonly"] }, { type: "input", label: "周期性", value: "", name: "cyclicalDesc", attrs: ["readonly"] }, { type: "textarea", label: "修改原因", value: "", name: "applyReason", rules: [{ required: true }] }, { type: "input", label: "修改前额度状态", value: "", name: "beforeStatusDesc", attrs: ["readonly"] }, { type: "select", label: "修改后额度状态", value: "", options: [], name: "updateStatus", attrs: ["filterable", "clearable", "collapse-tags"], // attrs: ["readonly"], rules: [{ required: true }] }, { type: "input", label: "修改前现金授信额度", value: "", name: "beforeCashCreditAmt", attrs: ["readonly"], isMoney: true }, { type: "input", label: "修改后现金授信额度", value: "", name: "updateCashCreditAmt", // attrs: ["readonly"], rules: [{ required: true }], isMoney: true }, { type: "input", label: "修改前消费授信额度", value: "", name: "beforeConsumeCreditAmt", attrs: ["readonly"], isMoney: true }, { type: "input", label: "修改后消费授信额度", value: "", name: "updateConsumeCreditAmt", // attrs: ["readonly"], rules: [{ required: true }], isMoney: true }, { type: "input", label: "修改前专项授信额度", value: "", name: "beforeSpecialCreditAmt", attrs: ["readonly"], isMoney: true }, { type: "input", label: "修改后专项授信额度", value: "", name: "updateSpecialCreditAmt", // attrs: ["readonly"], rules: [{ required: true }], isMoney: true } ]; // 基础额度 审核阶段 表单信息 const formListApprove = [ { type: "input", label: "客户编号", value: "", name: "customerId", attrs: ["readonly"] }, { type: "input", label: "客户名称", value: "", name: "customerName", attrs: ["readonly"] }, { type: "input", label: "证件类型", value: "", name: "certTypeDesc", attrs: ["readonly"] }, { type: "input", label: "证件号码", value: "", name: "certId", attrs: ["readonly"] }, { type: "input", label: "额度类型", value: "", name: "quotaTypeDesc", attrs: ["readonly"] }, { type: "input", label: "产品", value: "", name: "productName", attrs: ["readonly"] }, { type: "input", label: "周期性", value: "", name: "cyclicalDesc", attrs: ["readonly"] }, { type: "textarea", label: "修改原因", value: "", name: "applyReason", attrs: ["readonly"] // rules: [{ required: true }] }, { type: "input", label: "修改前额度状态", value: "", name: "beforeStatusDesc", attrs: ["readonly"] }, { type: "select", label: "修改后额度状态", value: "", options: [], name: "updateStatus", attrs: ["filterable", "clearable", "collapse-tags"], attrs: ["disabled"] // rules: [{ required: true }] }, { type: "input", label: "修改前现金授信额度", value: "", name: "beforeCashCreditAmt", attrs: ["readonly"], isMoney: true }, { type: "input", label: "修改后现金授信额度", value: "", name: "updateCashCreditAmt", attrs: ["readonly"], // rules: [{ required: true }], isMoney: true }, { type: "input", label: "修改前消费授信额度", value: "", name: "beforeConsumeCreditAmt", attrs: ["readonly"], isMoney: true }, { type: "input", label: "修改后消费授信额度", value: "", name: "updateConsumeCreditAmt", attrs: ["readonly"], // rules: [{ required: true }], isMoney: true }, { type: "input", label: "修改前专项授信额度", value: "", name: "beforeSpecialCreditAmt", attrs: ["readonly"], isMoney: true }, { type: "input", label: "修改后专项授信额度", value: "", name: "updateSpecialCreditAmt", attrs: ["readonly"], // rules: [{ required: true }], isMoney: true } ]; // 产品额度 申请阶段 表单信息 const formListPro = [ { type: "input", label: "客户编号", value: "", name: "customerId", attrs: ["readonly"] }, { type: "input", label: "客户名称", value: "", name: "customerName", attrs: ["readonly"] }, { type: "input", label: "证件类型", value: "", name: "certTypeDesc", attrs: ["readonly"] }, { type: "input", label: "证件号码", value: "", name: "certId", attrs: ["readonly"] }, { type: "input", label: "额度类型", value: "", name: "quotaTypeDesc", attrs: ["readonly"] }, { type: "input", label: "产品", value: "", name: "productName", attrs: ["readonly"] }, { type: "input", label: "周期性", value: "", name: "cyclicalDesc", attrs: ["readonly"] }, { type: "input", label: "额度状态", value: "", name: "beforeStatusDesc", attrs: ["readonly"] }, { type: "textarea", label: "修改原因", value: "", name: "applyReason", rules: [{ required: true }] }, { type: "input", label: "修改前现金授信额度", value: "", name: "beforeCashCreditAmt", attrs: ["readonly"], isMoney: true }, { type: "input", label: "修改后现金授信额度", value: "", name: "updateCashCreditAmt", // attrs: ["readonly"], rules: [{ required: true }], isMoney: true }, { type: "input", label: "修改前消费授信额度", value: "", name: "beforeConsumeCreditAmt", attrs: ["readonly"], isMoney: true }, { type: "input", label: "修改后消费授信额度", value: "", name: "updateConsumeCreditAmt", // attrs: ["readonly"], rules: [{ required: true }], isMoney: true }, { type: "input", label: "修改前专项授信额度", value: "", name: "beforeSpecialCreditAmt", attrs: ["readonly"], isMoney: true }, { type: "input", label: "修改后专项授信额度", value: "", name: "updateSpecialCreditAmt", // attrs: ["readonly"], rules: [{ required: true }], isMoney: true } ]; // 基础额度 审核阶段 表单信息 const formListApprovePro = [ { type: "input", label: "客户编号", value: "", name: "customerId", attrs: ["readonly"] }, { type: "input", label: "客户名称", value: "", name: "customerName", attrs: ["readonly"] }, { type: "input", label: "证件类型", value: "", name: "certTypeDesc", attrs: ["readonly"] }, { type: "input", label: "证件号码", value: "", name: "certId", attrs: ["readonly"] }, { type: "input", label: "额度类型", value: "", name: "quotaTypeDesc", attrs: ["readonly"] }, { type: "input", label: "产品", value: "", name: "productName", attrs: ["readonly"] }, { type: "input", label: "周期性", value: "", name: "cyclicalDesc", attrs: ["readonly"] }, { type: "input", label: "额度状态", value: "", name: "beforeStatusDesc", attrs: ["readonly"] }, { type: "textarea", label: "修改原因", value: "", name: "applyReason", attrs: ["readonly"] // rules: [{ required: true }] }, // { // type: "select", // label: "修改后额度状态", // value: "", // options: [], // name: "updateStatus", // attrs: ["filterable", "clearable", "collapse-tags"], // attrs: ["disabled"] // // rules: [{ required: true }] // }, { type: "input", label: "修改前现金授信额度", value: "", name: "beforeCashCreditAmt", attrs: ["readonly"], isMoney: true }, { type: "input", label: "修改后现金授信额度", value: "", name: "updateCashCreditAmt", attrs: ["readonly"], // rules: [{ required: true }], isMoney: true }, { type: "input", label: "修改前消费授信额度", value: "", name: "beforeConsumeCreditAmt", attrs: ["readonly"], isMoney: true }, { type: "input", label: "修改后消费授信额度", value: "", name: "updateConsumeCreditAmt", attrs: ["readonly"], // rules: [{ required: true }], isMoney: true }, { type: "input", label: "修改前专项授信额度", value: "", name: "beforeSpecialCreditAmt", attrs: ["readonly"], isMoney: true }, { type: "input", label: "修改后专项授信额度", value: "", name: "updateSpecialCreditAmt", attrs: ["readonly"], // rules: [{ required: true }], isMoney: true } ]; const approveList = [ { type: "select", label: "审批结果", value: "", options: [], name: "approveCode", attrs: ["filterable", "clearable", "collapse-tags"], // attrs: ["readonly"], rules: [{ required: true }] }, { type: "textarea", label: "审批意见", value: "", name: "approveOpinion" } ]; export default options => { const { approve, quotaType } = options; let tempList = null; // quotaType - 00 基础额度 01 产品额度 // 申请阶段 if (quotaType === "00") { tempList = [...formList]; } else { tempList = [...formListPro]; } // 审核阶段 if (approve) { if (quotaType === '00') { tempList = [...formListApprove, ...approveList]; }else { tempList = [...formListApprovePro, ...approveList] } } // 接口地址,required const api = "server/qryCustQuotDetail"; return new ApiModel({ api, formList: tempList, request(params) { return this.post(params); } }); };