Split model URLs for personal and corporate clients

This commit is contained in:
wkc
2026-04-27 15:22:08 +08:00
parent 5a80653917
commit 571f7bc075
20 changed files with 393 additions and 158 deletions

View File

@@ -82,19 +82,17 @@
</el-row>
<!-- 抵质押信息 -->
<el-divider content-position="left">抵质押信息</el-divider>
<el-row>
<el-divider v-if="isCollateralGuarantee" content-position="left">抵质押信息</el-divider>
<el-row v-if="isCollateralGuarantee">
<el-col :span="12">
<el-form-item label="抵质押类型" prop="collType">
<el-select v-model="form.collType" placeholder="请选择抵质押类型" style="width: 100%">
<el-option label="一类" value="一类"/>
<el-option label="二类" value="二类"/>
<el-option label="三类" value="三类"/>
<el-option v-for="item in collateralTypeOptions" :key="item" :label="item" :value="item"/>
</el-select>
</el-form-item>
</el-col>
<el-col :span="12">
<el-form-item label="抵质押物三方所有" prop="collThirdParty">
<el-form-item label="抵质押物是否第三方所有" prop="collThirdParty">
<el-switch v-model="form.collThirdParty"/>
</el-form-item>
</el-col>
@@ -194,6 +192,18 @@ export default {
set(val) {
this.$emit('update:visible', val)
}
},
isCollateralGuarantee() {
return this.form.guarType === '抵押' || this.form.guarType === '质押'
},
collateralTypeOptions() {
if (this.form.guarType === '抵押') {
return ['一类', '二类', '三类', '四类', '其他']
}
if (this.form.guarType === '质押') {
return ['存单质押', '其他']
}
return []
}
},
watch: {
@@ -201,6 +211,11 @@ export default {
if (val) {
this.reset()
}
},
'form.guarType'(val, oldVal) {
if (val !== oldVal) {
this.resetCollateralFields()
}
}
},
methods: {
@@ -234,6 +249,16 @@ export default {
this.dialogVisible = false
this.reset()
},
/** 清空抵质押字段 */
resetCollateralFields() {
this.form.collType = undefined
this.form.collThirdParty = false
this.$nextTick(() => {
if (this.$refs.form) {
this.$refs.form.clearValidate(['collType', 'collThirdParty'])
}
})
},
/** 提交按钮 */
submitForm() {
this.$refs["form"].validate(valid => {
@@ -243,8 +268,13 @@ export default {
const data = {
...this.form,
bizProof: this.form.bizProof ? '1' : '0',
loanLoop: this.form.loanLoop ? '1' : '0',
collThirdParty: this.form.collThirdParty ? '1' : '0'
loanLoop: this.form.loanLoop ? '1' : '0'
}
if (this.isCollateralGuarantee) {
data.collThirdParty = this.form.collThirdParty ? '1' : '0'
} else {
delete data.collType
delete data.collThirdParty
}
createPersonalWorkflow(data).then(response => {