yujialong 9 months ago
parent fa6e48314e
commit b455947c6a
  1. 29
      src/views/product/bank/Add.vue
  2. 235
      src/views/product/bank/Config.vue
  3. 2
      src/views/product/fund/Add.vue

@ -171,7 +171,7 @@
:label="item.itemId">{{ item.options }}</el-radio> :label="item.itemId">{{ item.options }}</el-radio>
</template> </template>
<template v-else> <template v-else>
<el-radio v-for="(item, i) in config.find((e) => e.name === '个人产品-贷款用途')?.recordChildren" <el-radio v-for="(item, i) in config.find(e => e.name === '个人产品-贷款用途')?.recordChildren"
:key="i" :key="i"
:label="item.id">{{ item.name }}</el-radio> :label="item.id">{{ item.name }}</el-radio>
</template> </template>
@ -186,12 +186,11 @@
<el-form-item label="担保方式" <el-form-item label="担保方式"
prop="bankGuaranteeTypeIds" prop="bankGuaranteeTypeIds"
:rules="[ :rules="[
{ required: true, message: '请选择担保方式', trigger: 'change' },
{ {
asyncValidator: async (rule, value, callback) => { asyncValidator: async (rule, value, callback) => {
if (value.includes(110) && !value.find((e) => e > 22 && e < 33)) { if (form.bankGuarantee3 === 795 && !value.find(e => e > 22 && e < 33)) {
callback('请选择抵押物') callback('请选择抵押物')
} else if (value.includes(111) && !value.find((e) => e > 32 && e < 38)) { } else if (form.bankGuarantee4 === 795 && !value.find(e => e > 32 && e < 38)) {
callback('请选择质押贷') callback('请选择质押贷')
} else { } else {
callback() callback()
@ -358,7 +357,6 @@ interface RuleForm {
educationalRequirements?: any; educationalRequirements?: any;
loanCeiling: any; loanCeiling: any;
loanPurpose: any; loanPurpose: any;
productObject: any;
maximumAge: any; maximumAge: any;
maximumAnnualInterestRate: any; maximumAnnualInterestRate: any;
maximumTermOfLoan: any; maximumTermOfLoan: any;
@ -412,7 +410,6 @@ const form = reactive<RuleForm>({
educationalRequirements: [], educationalRequirements: [],
loanCeiling: '', loanCeiling: '',
loanPurpose: '', loanPurpose: '',
productObject: '',
maximumAge: '', maximumAge: '',
maximumAnnualInterestRate: '', maximumAnnualInterestRate: '',
maximumTermOfLoan: '', maximumTermOfLoan: '',
@ -498,7 +495,6 @@ const submit = async (formEl: FormInstance | undefined) => {
if (!param.productType) { if (!param.productType) {
if (param.edu === 795 && !param.educationalRequirements.length) return ElMessage.error('请选择学历要求'); if (param.edu === 795 && !param.educationalRequirements.length) return ElMessage.error('请选择学历要求');
if (param.curWL === 795 && !param.currentWorkingLife.length) return ElMessage.error('请选择工作年限'); if (param.curWL === 795 && !param.currentWorkingLife.length) return ElMessage.error('请选择工作年限');
if (param.curWL === 795 && !param.currentWorkingLife.length) return ElMessage.error('请选择工作年限');
} }
if (isIllegalNum(param.minimumLoan) || isIllegalNum(param.loanCeiling) || +param.minimumLoan > +param.loanCeiling) return ElMessage.error('请输入合理的贷款额度'); if (isIllegalNum(param.minimumLoan) || isIllegalNum(param.loanCeiling) || +param.minimumLoan > +param.loanCeiling) return ElMessage.error('请输入合理的贷款额度');
if (isIllegalNum(param.minimumAprOnLoan) || isIllegalNum(param.maximumAnnualInterestRate) || +param.minimumAprOnLoan > +param.maximumAnnualInterestRate) if (isIllegalNum(param.minimumAprOnLoan) || isIllegalNum(param.maximumAnnualInterestRate) || +param.minimumAprOnLoan > +param.maximumAnnualInterestRate)
@ -508,7 +504,7 @@ const submit = async (formEl: FormInstance | undefined) => {
param.currentWorkingLife = param.currentWorkingLife.join(); param.currentWorkingLife = param.currentWorkingLife.join();
param.educationalRequirements = param.educationalRequirements.join(); param.educationalRequirements = param.educationalRequirements.join();
param.modeRepayment = param.modeRepayment.join(); param.modeRepayment = param.modeRepayment.join();
param.providentFundAndSocialSecurity = param.providentFundAndSocialSecurity === 795 ? 1 : ''; // param.providentFundAndSocialSecurity = param.providentFundAndSocialSecurity === 795 ? 1 : '';
param.whetherToSupportEarlyRepayment = param.whetherToSupportEarlyRepayment ? 58 : ''; param.whetherToSupportEarlyRepayment = param.whetherToSupportEarlyRepayment ? 58 : '';
// //
const graIds = []; const graIds = [];
@ -553,7 +549,6 @@ const submit = async (formEl: FormInstance | undefined) => {
} }
}); });
param.addBankProductsGuarantyStyleReqList = graIds; param.addBankProductsGuarantyStyleReqList = graIds;
debugger;
let res; let res;
if (id.value) { if (id.value) {
param.id = id.value; param.id = id.value;
@ -565,7 +560,7 @@ const submit = async (formEl: FormInstance | undefined) => {
addRecord(param); addRecord(param);
} }
router.push(`/product/bank/detail?type=${route.query.type || ''}&i=${route.query.i}&role=${route.query.role}&id=${res.message}`); router.push(`/product/bank/detail?type=${route.query.type || ''}&i=${route.query.i}&role=${route.query.role}&id=${res?.message || ''}`);
ElMessage.success('提交成功!'); ElMessage.success('提交成功!');
emit('getList'); emit('getList');
} finally { } finally {
@ -595,10 +590,16 @@ const addRecord = async (data: Record<string, any>) => {
); );
} else { } else {
// //
data.age === 795 && lcRule.push(handleId(100, 41, data.minimumAge + '~' + data.maximumAge + '', preIds + ',51,100', 5)); data.age && lcRule.push(handleId(1235, 324, data.age, preIds + ',51,1234,1235', 1));
data.edu === 795 && lcRule.push(handleId(101, 42, data.educationalRequirements, preIds + ',51,101', 1)); data.age === 795 && lcRule.push(handleId(1236, 41, data.minimumAge + '~' + data.maximumAge, preIds + ',51,1234,1236', 5));
data.curWL === 795 && lcRule.push(handleId(102, 43, data.currentWorkingLife, preIds + ',51,102', 1));
data.providentFundAndSocialSecurity === 795 && lcRule.push(handleId(103, '', '', preIds + ',51,103', '')); // data.edu && lcRule.push(handleId(1238, 324, data.edu, preIds + ',51,1237,1238', 1));
data.edu === 795 && lcRule.push(handleId(1239, 42, data.educationalRequirements, preIds + ',51,1237,1239', 1));
data.curWL && lcRule.push(handleId(1241, 324, data.curWL, preIds + ',51,1240,1241', 1));
data.curWL === 795 && lcRule.push(handleId(1242, 43, data.currentWorkingLife, preIds + ',51,1240,1242', 1));
data.providentFundAndSocialSecurity && lcRule.push(handleId(1244, 324, data.providentFundAndSocialSecurity, preIds + ',51,1243,1244', 1)); //
lcRule.push( lcRule.push(
data.loanPurpose === 107 ? handleId(107, 11, data.otherPurposesOfLoan, preIds + ',52,107', 3) : handleId(data.loanPurpose, '', '', preIds + ',52,' + data.loanPurpose, ''), data.loanPurpose === 107 ? handleId(107, 11, data.otherPurposesOfLoan, preIds + ',52,107', 3) : handleId(data.loanPurpose, '', '', preIds + ',52,' + data.loanPurpose, ''),

@ -21,28 +21,31 @@
:key="i" :key="i"
:label="item.id">{{ item.name }}</el-radio> :label="item.id">{{ item.name }}</el-radio>
</el-radio-group> </el-radio-group>
<p class="whether mt-1">选择需要提供的申请人材料至少选一样</p>
</div> </div>
<el-checkbox-group v-if="form.accountMaterialsCheck === 797" <template v-if="form.accountMaterialsCheck === 797">
v-model="form.accountMaterials"> <p class="tips">选择需要提供的申请人材料至少选一样</p>
<el-checkbox v-for="(item, i) in config[0]?.recordChildren[0]?.subject?.itemList" <el-checkbox-group v-if="config.length"
:key="i" v-model="form.accountMaterials">
:label="item.itemId">{{ item.options }}</el-checkbox> <el-checkbox v-for="(item, i) in config[0]?.recordChildren[0]?.subject?.itemList"
</el-checkbox-group> :key="i"
:label="item.itemId">{{ item.options }}</el-checkbox>
</el-checkbox-group>
</template>
</div> </div>
</el-form-item> </el-form-item>
<el-form-item label="发放账户" <el-form-item label="发放账户"
prop="sendingAccount"> prop="sendingAccount">
<div> <div>
<div class="radio-wrap flex-col items-start"> <div class="radio-wrap flex-col items-start">
<el-radio-group v-model="form.sendingAccountCheck"> <el-radio-group v-if="config.length"
v-model="form.sendingAccountCheck">
<el-radio v-for="(item, i) in config[0]?.recordChildren[1]?.recordChildren[0]?.subject?.itemList" <el-radio v-for="(item, i) in config[0]?.recordChildren[1]?.recordChildren[0]?.subject?.itemList"
:key="i" :key="i"
:label="item.itemId">{{ item.options }}</el-radio> :label="item.itemId">{{ item.options }}</el-radio>
</el-radio-group> </el-radio-group>
<p class="whether mt-1">选择需要发放的账户至少选一样</p>
</div> </div>
<template v-if="form.sendingAccountCheck === 801"> <template v-if="form.sendingAccountCheck === 801 && config.length">
<p class="tips">选择需要发放的账户至少选一样</p>
<el-radio v-for="(item, i) in config[0]?.recordChildren[1]?.subject?.itemList" <el-radio v-for="(item, i) in config[0]?.recordChildren[1]?.subject?.itemList"
:key="i" :key="i"
v-model="form.sendingAccount" v-model="form.sendingAccount"
@ -56,7 +59,8 @@
<el-form-item label="申请方式" <el-form-item label="申请方式"
prop="loanApplicationMethod"> prop="loanApplicationMethod">
<p class="mr-5 text-xs text-[#666]">选择申请方式至少选一样</p> <p class="mr-5 text-xs text-[#666]">选择申请方式至少选一样</p>
<el-checkbox-group v-model="form.loanApplicationMethod"> <el-checkbox-group v-if="config.length"
v-model="form.loanApplicationMethod">
<el-checkbox v-for="(item, i) in config[1]?.recordChildren[0]?.subject?.itemList" <el-checkbox v-for="(item, i) in config[1]?.recordChildren[0]?.subject?.itemList"
:key="i" :key="i"
:label="item.itemId">{{ item.options }}</el-checkbox> :label="item.itemId">{{ item.options }}</el-checkbox>
@ -75,9 +79,10 @@
</el-radio-group> </el-radio-group>
</div> </div>
</div> </div>
<p class="text-xs text-[#666]">选择需要提供的借款人材料至少选一样</p>
<div v-if="form.borrowerMaterialCheck === 797"> <div v-if="form.borrowerMaterialCheck === 797">
<el-select class="my-2" <p class="text-xs text-[#666]">选择需要提供的借款人材料至少选一样</p>
<el-select v-if="config.length"
class="my-2"
v-model="form.borrowerMaterialSelect" v-model="form.borrowerMaterialSelect"
placeholder="请选择"> placeholder="请选择">
<el-option v-for="item in config[1]?.recordChildren[1]?.recordChildren[1]?.subject?.itemList" <el-option v-for="item in config[1]?.recordChildren[1]?.recordChildren[1]?.subject?.itemList"
@ -85,7 +90,8 @@
:label="item.options" :label="item.options"
:value="item.itemId" /> :value="item.itemId" />
</el-select> </el-select>
<el-checkbox-group v-model="form.borrowerMaterial" <el-checkbox-group v-if="config.length"
v-model="form.borrowerMaterial"
@change="denyAll('borrowerMaterial', 770)"> @change="denyAll('borrowerMaterial', 770)">
<el-checkbox v-for="(item, i) in config[1]?.recordChildren[1]?.recordChildren[0]?.subject?.itemList" <el-checkbox v-for="(item, i) in config[1]?.recordChildren[1]?.recordChildren[0]?.subject?.itemList"
:key="i" :key="i"
@ -103,15 +109,17 @@
:key="i" :key="i"
:label="item.id">{{ item.name }}</el-radio> :label="item.id">{{ item.name }}</el-radio>
</el-radio-group> </el-radio-group>
<p class="whether mt-1">选择需要提供的企业材料至少选一样</p>
</div> </div>
<el-checkbox-group v-if="form.enterpriseMaterialCheck === 797" <template v-if="form.enterpriseMaterialCheck === 797">
v-model="form.enterpriseMaterial"> <p class="tips">选择需要提供的企业材料至少选一样</p>
<el-checkbox v-for="(item, i) in config[1]?.recordChildren[2]?.subject?.itemList" <el-checkbox-group v-if="config.length"
:key="i" v-model="form.enterpriseMaterial">
:label="item.itemId">{{ item.options }}</el-checkbox> <el-checkbox v-for="(item, i) in config[1]?.recordChildren[2]?.subject?.itemList"
</el-checkbox-group> :key="i"
:label="item.itemId">{{ item.options }}</el-checkbox>
</el-checkbox-group>
</template>
</div> </div>
<p class="field-name mt-5">抵押物</p> <p class="field-name mt-5">抵押物</p>
<div> <div>
@ -121,14 +129,16 @@
:key="i" :key="i"
:label="item.id">{{ item.name }}</el-radio> :label="item.id">{{ item.name }}</el-radio>
</el-radio-group> </el-radio-group>
<p class="whether mt-1">选择需要提供的抵押物材料至少选一样</p>
</div> </div>
<el-checkbox-group v-if="form.collateralCheck === 797" <template v-if="form.collateralCheck === 797">
v-model="form.collateral"> <p class="tips">选择需要提供的抵押物材料至少选一样</p>
<el-checkbox v-for="(item, i) in config[1]?.recordChildren[3]?.subject?.itemList" <el-checkbox-group v-if="config.length"
:key="i" v-model="form.collateral">
:label="item.itemId">{{ item.options }}</el-checkbox> <el-checkbox v-for="(item, i) in config[1]?.recordChildren[3]?.subject?.itemList"
</el-checkbox-group> :key="i"
:label="item.itemId">{{ item.options }}</el-checkbox>
</el-checkbox-group>
</template>
</div> </div>
</template> </template>
<!-- 个人 --> <!-- 个人 -->
@ -141,16 +151,18 @@
:key="i" :key="i"
:label="item.id">{{ item.name }}</el-radio> :label="item.id">{{ item.name }}</el-radio>
</el-radio-group> </el-radio-group>
<p class="whether mt-1">选择需要提供的配偶材料至少选一样</p>
</div> </div>
<el-checkbox-group v-if="form.mateMaterialCheck === 797" <template v-if="form.mateMaterialCheck === 797">
v-model="form.mateMaterial" <p class="tips">选择需要提供的配偶材料至少选一样</p>
@change="denyAll('mateMaterial', 350)"> <el-checkbox-group v-if="config.length"
<el-checkbox v-for="(item, i) in config[1]?.recordChildren[2]?.subject?.itemList" v-model="form.mateMaterial"
:key="i" @change="denyAll('mateMaterial', 350)">
:label="item.itemId">{{ item.options }}</el-checkbox> <el-checkbox v-for="(item, i) in config[1]?.recordChildren[2]?.subject?.itemList"
</el-checkbox-group> :key="i"
:label="item.itemId">{{ item.options }}</el-checkbox>
</el-checkbox-group>
</template>
</div> </div>
<p class="field-name mt-5">经营类材料</p> <p class="field-name mt-5">经营类材料</p>
<div> <div>
@ -160,16 +172,18 @@
:key="i" :key="i"
:label="item.id">{{ item.name }}</el-radio> :label="item.id">{{ item.name }}</el-radio>
</el-radio-group> </el-radio-group>
<p class="whether mt-1">选择需要提供的经营类材料至少选一样</p>
</div> </div>
<el-checkbox-group v-if="form.businessMaterialsCheck === 797" <template v-if="form.businessMaterialsCheck === 797">
v-model="form.businessMaterials" <p class="tips">选择需要提供的经营类材料至少选一样</p>
@change="denyAll('businessMaterials', 351)"> <el-checkbox-group v-if="config.length"
<el-checkbox v-for="(item, i) in config[1]?.recordChildren[3]?.subject?.itemList" v-model="form.businessMaterials"
:key="i" @change="denyAll('businessMaterials', 351)">
:label="item.itemId">{{ item.options }}</el-checkbox> <el-checkbox v-for="(item, i) in config[1]?.recordChildren[3]?.subject?.itemList"
</el-checkbox-group> :key="i"
:label="item.itemId">{{ item.options }}</el-checkbox>
</el-checkbox-group>
</template>
</div> </div>
</template> </template>
<p class="field-name mt-5">补充材料</p> <p class="field-name mt-5">补充材料</p>
@ -180,16 +194,18 @@
:key="i" :key="i"
:label="item.id">{{ item.name }}</el-radio> :label="item.id">{{ item.name }}</el-radio>
</el-radio-group> </el-radio-group>
<p class="whether mt-1">选择需要提供的补充材料至少选一样</p>
</div> </div>
<el-checkbox-group v-if="form.supplementaryMaterialsCheck === 797" <template v-if="form.supplementaryMaterialsCheck === 797">
v-model="form.supplementaryMaterials" <p class="tips">选择需要提供的补充材料至少选一样</p>
@change="denyAll('supplementaryMaterials', 352)"> <el-checkbox-group v-if="config.length"
<el-checkbox v-for="(item, i) in config[1]?.recordChildren[4]?.subject?.itemList" v-model="form.supplementaryMaterials"
:key="i" @change="denyAll('supplementaryMaterials', 352)">
:label="item.itemId">{{ item.options }}</el-checkbox> <el-checkbox v-for="(item, i) in config[1]?.recordChildren[4]?.subject?.itemList"
</el-checkbox-group> :key="i"
:label="item.itemId">{{ item.options }}</el-checkbox>
</el-checkbox-group>
</template>
</div> </div>
</div> </div>
</el-form-item> </el-form-item>
@ -200,38 +216,44 @@
prop="runBatchObject"> prop="runBatchObject">
<div> <div>
<div class="radio-wrap flex-col items-start mb-2"> <div class="radio-wrap flex-col items-start mb-2">
<el-radio-group v-model="form.runBatchObjectCheck"> <el-radio-group v-if="config.length"
v-model="form.runBatchObjectCheck">
<el-radio v-for="(item, i) in config[2]?.recordChildren[0]?.recordChildren[0]?.subject?.itemList" <el-radio v-for="(item, i) in config[2]?.recordChildren[0]?.recordChildren[0]?.subject?.itemList"
:key="i" :key="i"
:label="item.itemId">{{ item.options }}</el-radio> :label="item.itemId">{{ item.options }}</el-radio>
</el-radio-group> </el-radio-group>
<p class="whether mt-1">选择需要跑批的对象至少选一样</p>
</div> </div>
<el-checkbox-group v-if="form.runBatchObjectCheck === 803" <template v-if="form.runBatchObjectCheck === 797">
v-model="form.runBatchObject"> <p class="tips">选择需要跑批的对象至少选一样</p>
<el-checkbox v-for="(item, i) in config[2]?.recordChildren[0]?.subject?.itemList" <el-checkbox-group v-if="config.length"
:key="i" v-model="form.runBatchObject">
:label="item.itemId">{{ item.options }}</el-checkbox> <el-checkbox v-for="(item, i) in config[2]?.recordChildren[0]?.subject?.itemList"
</el-checkbox-group> :key="i"
:label="item.itemId">{{ item.options }}</el-checkbox>
</el-checkbox-group>
</template>
</div> </div>
</el-form-item> </el-form-item>
<el-form-item label="准入策略" <el-form-item label="准入策略"
prop="accessStrategy"> prop="accessStrategy">
<div> <div>
<div class="radio-wrap flex-col items-start mb-2"> <div class="radio-wrap flex-col items-start mb-2">
<el-radio-group v-model="form.accessStrategyCheck"> <el-radio-group v-if="config.length"
v-model="form.accessStrategyCheck">
<el-radio v-for="(item, i) in config[2]?.recordChildren[1]?.recordChildren[0]?.subject?.itemList" <el-radio v-for="(item, i) in config[2]?.recordChildren[1]?.recordChildren[0]?.subject?.itemList"
:key="i" :key="i"
:label="item.itemId">{{ item.options }}</el-radio> :label="item.itemId">{{ item.options }}</el-radio>
</el-radio-group> </el-radio-group>
<p class="whether mt-1">选择需要跑批的准入策略至少选一样</p>
</div> </div>
<el-checkbox-group v-if="form.accessStrategyCheck === 803" <template v-if="form.accessStrategyCheck === 797">
v-model="form.accessStrategy"> <p class="tips">选择需要跑批的准入策略至少选一样</p>
<el-checkbox v-for="(item, i) in config[2]?.recordChildren[1]?.subject?.itemList" <el-checkbox-group v-if="config.length"
:key="i" v-model="form.accessStrategy">
:label="item.itemId">{{ item.options }}</el-checkbox> <el-checkbox v-for="(item, i) in config[2]?.recordChildren[1]?.subject?.itemList"
</el-checkbox-group> :key="i"
:label="item.itemId">{{ item.options }}</el-checkbox>
</el-checkbox-group>
</template>
</div> </div>
</el-form-item> </el-form-item>
<el-form-item label="信用评分策略" <el-form-item label="信用评分策略"
@ -282,14 +304,15 @@
prop="riskDegreeStrategy"> prop="riskDegreeStrategy">
<div class="flex items-center h-[47px]"> <div class="flex items-center h-[47px]">
<div class="radio-wrap"> <div class="radio-wrap">
<el-radio-group v-model="form.riskDegreeStrategyCheck"> <el-radio-group v-if="config.length"
v-model="form.riskDegreeStrategyCheck">
<el-radio v-for="(item, i) in config[2]?.recordChildren[3]?.recordChildren[0]?.subject?.itemList" <el-radio v-for="(item, i) in config[2]?.recordChildren[3]?.recordChildren[0]?.subject?.itemList"
:key="i" :key="i"
:label="item.itemId">{{ item.options }}</el-radio> :label="item.itemId">{{ item.options }}</el-radio>
</el-radio-group> </el-radio-group>
</div> </div>
<el-checkbox-group v-if="form.riskDegreeStrategyCheck === 803" <el-checkbox-group v-if="form.riskDegreeStrategyCheck === 803 && config.length"
v-model="form.riskDegreeStrategy"> v-model="form.riskDegreeStrategy">
<el-checkbox v-for="(item, i) in config[2]?.recordChildren[3]?.subject?.itemList" <el-checkbox v-for="(item, i) in config[2]?.recordChildren[3]?.subject?.itemList"
:key="i" :key="i"
@ -305,13 +328,14 @@
<div class="flex items-center mb-3"> <div class="flex items-center mb-3">
<div class="radio-wrap"> <div class="radio-wrap">
<span class="label">{{ (info.productType ? '企业' : '个人') + '额度模型' }}</span> <span class="label">{{ (info.productType ? '企业' : '个人') + '额度模型' }}</span>
<el-radio-group v-model="form.interestRatePricingModelCheck"> <el-radio-group v-if="config.length"
v-model="form.interestRatePricingModelCheck">
<el-radio v-for="(item, i) in config[2]?.recordChildren[3]?.recordChildren[0]?.subject?.itemList" <el-radio v-for="(item, i) in config[2]?.recordChildren[3]?.recordChildren[0]?.subject?.itemList"
:key="i" :key="i"
:label="item.itemId">{{ item.options }}</el-radio> :label="item.itemId">{{ item.options }}</el-radio>
</el-radio-group> </el-radio-group>
</div> </div>
<el-select v-if="form.interestRatePricingModelCheck === 803" <el-select v-if="form.interestRatePricingModelCheck === 803 && config.length"
class="ml-5" class="ml-5"
v-model="form.interestRatePricingModel" v-model="form.interestRatePricingModel"
placeholder="请选择"> placeholder="请选择">
@ -324,7 +348,8 @@
<div class="radio-wrap"> <div class="radio-wrap">
<span class="label">{{ (info.productType ? '企业' : '个人') + '利率模型' }}</span> <span class="label">{{ (info.productType ? '企业' : '个人') + '利率模型' }}</span>
<el-radio-group v-model="form.individualInterestRateModel"> <el-radio-group v-if="config.length"
v-model="form.individualInterestRateModel">
<el-radio v-for="(item, i) in config[2]?.recordChildren[4]?.recordChildren[0]?.recordChildren[0]?.subject?.itemList" <el-radio v-for="(item, i) in config[2]?.recordChildren[4]?.recordChildren[0]?.recordChildren[0]?.subject?.itemList"
:key="i" :key="i"
:label="item.itemId">{{ item.options }}</el-radio> :label="item.itemId">{{ item.options }}</el-radio>
@ -339,7 +364,8 @@
prop="dueDiligenceMode"> prop="dueDiligenceMode">
<div> <div>
<p class="tips leading-[32px]">选择尽调方式至少选一样</p> <p class="tips leading-[32px]">选择尽调方式至少选一样</p>
<el-radio-group v-model="form.dueDiligenceMode"> <el-radio-group v-if="config.length"
v-model="form.dueDiligenceMode">
<el-radio v-for="(item, i) in config[3]?.recordChildren[0]?.subject?.itemList" <el-radio v-for="(item, i) in config[3]?.recordChildren[0]?.subject?.itemList"
:key="i" :key="i"
:label="item.itemId">{{ item.options }}</el-radio> :label="item.itemId">{{ item.options }}</el-radio>
@ -350,7 +376,8 @@
prop="dueDiligenceContent"> prop="dueDiligenceContent">
<div> <div>
<p class="tips leading-[32px]">选择尽调内容至少选一样</p> <p class="tips leading-[32px]">选择尽调内容至少选一样</p>
<el-checkbox-group v-model="form.dueDiligenceContent"> <el-checkbox-group v-if="config.length"
v-model="form.dueDiligenceContent">
<el-checkbox v-for="(item, i) in config[3]?.recordChildren[1]?.subject?.itemList" <el-checkbox v-for="(item, i) in config[3]?.recordChildren[1]?.subject?.itemList"
:key="i" :key="i"
:label="item.itemId">{{ item.options }}</el-checkbox> :label="item.itemId">{{ item.options }}</el-checkbox>
@ -401,7 +428,7 @@
<el-form-item label="提供的材料" <el-form-item label="提供的材料"
prop="contractMaterials"> prop="contractMaterials">
<div class="flex items-center"> <div class="flex items-center">
<div class="radio-wrap"> <div class="radio-wrap mr-5">
<el-radio-group v-model="form.contractMaterialsCheck"> <el-radio-group v-model="form.contractMaterialsCheck">
<el-radio v-for="(item, i) in whethers" <el-radio v-for="(item, i) in whethers"
:key="i" :key="i"
@ -425,7 +452,7 @@
</el-radio-group> </el-radio-group>
</div> </div>
<el-select v-if="form.loanContractCheck === 797" <el-select v-if="form.loanContractCheck === 797 && config.length"
class="ml-5" class="ml-5"
v-model="form.loanContract" v-model="form.loanContract"
placeholder="请选择"> placeholder="请选择">
@ -445,7 +472,7 @@
</el-radio-group> </el-radio-group>
</div> </div>
<el-select v-if="form.mortgageContractCheck === 797" <el-select v-if="form.mortgageContractCheck === 797 && config.length"
class="ml-5" class="ml-5"
v-model="form.mortgageContract" v-model="form.mortgageContract"
placeholder="请选择"> placeholder="请选择">
@ -464,7 +491,7 @@
:label="item.id">{{ item.name }}</el-radio> :label="item.id">{{ item.name }}</el-radio>
</el-radio-group> </el-radio-group>
</div> </div>
<el-select v-if="form.pledgeContractCheck === 797" <el-select v-if="form.pledgeContractCheck === 797 && config.length"
class="ml-5" class="ml-5"
v-model="form.pledgeContract" v-model="form.pledgeContract"
placeholder="请选择"> placeholder="请选择">
@ -483,7 +510,7 @@
:label="item.id">{{ item.name }}</el-radio> :label="item.id">{{ item.name }}</el-radio>
</el-radio-group> </el-radio-group>
</div> </div>
<el-select v-if="form.guaranteeContractCheck === 797" <el-select v-if="form.guaranteeContractCheck === 797 && config.length"
class="ml-5" class="ml-5"
v-model="form.guaranteeContract" v-model="form.guaranteeContract"
placeholder="请选择"> placeholder="请选择">
@ -502,19 +529,22 @@
prop="selectionStrategy"> prop="selectionStrategy">
<div> <div>
<div class="radio-wrap flex-col items-start mb-1"> <div class="radio-wrap flex-col items-start mb-1">
<el-radio-group v-model="form.selectionStrategyCheck"> <el-radio-group v-if="config.length"
<el-radio v-for="(item, i) in info.productType ? config[7]?.recordChildren[0]?.recordChildren[0]?.subject?.itemList : config[7]?.recordChildren[0]?.subject?.itemList" v-model="form.selectionStrategyCheck">
<el-radio v-for="(item, i) in config[2]?.recordChildren[0]?.recordChildren[0]?.subject?.itemList"
:key="i" :key="i"
:label="item.itemId">{{ item.options }}</el-radio> :label="item.itemId">{{ item.options }}</el-radio>
</el-radio-group> </el-radio-group>
<p class="whether mt-1">选择策略至少选一样</p>
</div> </div>
<el-checkbox-group v-if="form.selectionStrategyCheck === 803" <template v-if="form.selectionStrategyCheck === 803">
v-model="form.selectionStrategy"> <p class="tips">选择策略至少选一样</p>
<el-checkbox v-for="(item, i) in info.productType ? config[7]?.recordChildren[0]?.subject?.itemList : config[7]?.subject?.itemList" <el-checkbox-group v-if="(info.productType && config.length && config[7]?.recordChildren) || (!info.productType && config.length && config[7]?.subject)"
:key="i" v-model="form.selectionStrategy">
:label="item.itemId">{{ item.options }}</el-checkbox> <el-checkbox v-for="(item, i) in info.productType ? config[7]?.recordChildren[0]?.subject?.itemList : config[7]?.subject?.itemList"
</el-checkbox-group> :key="i"
:label="item.itemId">{{ item.options }}</el-checkbox>
</el-checkbox-group>
</template>
</div> </div>
</el-form-item> </el-form-item>
</div> </div>
@ -731,6 +761,32 @@ const submit = async (formEl: FormInstance | undefined) => {
const isEnterprise = info.value.productType === 1; const isEnterprise = info.value.productType === 1;
const param = JSON.parse(JSON.stringify(form)); const param = JSON.parse(JSON.stringify(form));
if (param.accountMaterialsCheck === 797 && !param.accountMaterials.length) return ElMessage.error('请选择需要提供的申请人材料');
if (param.sendingAccountCheck === 801 && !param.sendingAccount) return ElMessage.error('请选择需要发放的账户');
if (!param.loanApplicationMethod.length) return ElMessage.error('请选择申请方式');
if (param.borrowerMaterialCheck === 797 && !param.borrowerMaterialSelect && !param.borrowerMaterial.length) return ElMessage.error('请选择需要提供的借款人材料');
if (isEnterprise) {
//
if (param.enterpriseMaterialCheck === 797 && !param.enterpriseMaterial.length) return ElMessage.error('请选择需要提供的企业材料');
if (param.collateralCheck === 797 && !param.collateral.length) return ElMessage.error('请选择需要提供的抵押物材料');
} else {
//
if (param.mateMaterialCheck === 797 && !param.mateMaterial.length) return ElMessage.error('请选择需要提供的配偶材料');
if (param.businessMaterialsCheck === 797 && !param.businessMaterials.length) return ElMessage.error('请选择需要提供的经营类材料');
}
if (param.supplementaryMaterialsCheck === 797 && !param.supplementaryMaterials.length) return ElMessage.error('请选择需要提供的补充材料');
if (param.runBatchObjectCheck === 797 && !param.runBatchObject.length) return ElMessage.error('请选择需要跑批的对象');
if (param.accessStrategyCheck === 797 && !param.accessStrategy.length) return ElMessage.error('请选择需要跑批的准入策略');
if (!param.dueDiligenceMode) return ElMessage.error('请选择尽调方式');
if (!param.dueDiligenceContent.length) return ElMessage.error('请选择尽调内容');
if (!param.reviewContent) return ElMessage.error('请选择审查材料');
if (!param.reviewSignature) return ElMessage.error('请选择签字表单');
if (!param.reviewApproveContent) return ElMessage.error('请选择审批材料');
if (!param.approvalSignature) return ElMessage.error('请选择签字表单');
if (param.selectionStrategyCheck === 803 && !param.selectionStrategy.length) return ElMessage.error('请选择策略');
param.accessStrategy = param.accessStrategyCheck === 797 ? param.accessStrategy.join() : ''; param.accessStrategy = param.accessStrategyCheck === 797 ? param.accessStrategy.join() : '';
if (param.borrowerMaterialCheck === 797) param.borrowerMaterial.unshift(param.borrowerMaterialSelect); if (param.borrowerMaterialCheck === 797) param.borrowerMaterial.unshift(param.borrowerMaterialSelect);
param.borrowerMaterial = param.borrowerMaterial.join(); param.borrowerMaterial = param.borrowerMaterial.join();
@ -759,6 +815,7 @@ const submit = async (formEl: FormInstance | undefined) => {
param.runBatchObject = param.runBatchObjectCheck === 797 ? param.runBatchObject.join() : ''; param.runBatchObject = param.runBatchObjectCheck === 797 ? param.runBatchObject.join() : '';
param.selectionStrategy = param.selectionStrategyCheck === 803 ? param.selectionStrategy.join() : ''; param.selectionStrategy = param.selectionStrategyCheck === 803 ? param.selectionStrategy.join() : '';
param.supplementaryMaterials = param.supplementaryMaterialsCheck === 797 ? param.supplementaryMaterials.join() : ''; param.supplementaryMaterials = param.supplementaryMaterialsCheck === 797 ? param.supplementaryMaterials.join() : '';
debugger;
if (param.contractMaterialsCheck !== 797) param.contractMaterials = ''; if (param.contractMaterialsCheck !== 797) param.contractMaterials = '';
if (info.value.riskControlDetails) { if (info.value.riskControlDetails) {
param.id = info.value.riskControlDetails.id; param.id = info.value.riskControlDetails.id;

@ -284,7 +284,7 @@
</el-select> </el-select>
</div> </div>
<div> <div v-if="i">
<el-icon class="cursor-pointer" <el-icon class="cursor-pointer"
:size="16" :size="16"
color="#333" color="#333"

Loading…
Cancel
Save