mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-24 13:42:52 +08:00
回显bug修改
This commit is contained in:
@@ -1,12 +1,29 @@
|
||||
import { getBankList } from '@/api/ebiz/sale/sale'
|
||||
export default function getBankName(data, code) {
|
||||
import bankListJson from '@/views/ebiz/agentEenter/js/bankList.js'
|
||||
|
||||
export function getBankName(code) {
|
||||
if (code) {
|
||||
let list = data.filter(item => {
|
||||
return item.code == code
|
||||
let bank = bankListJson.find(item => {
|
||||
return item.code === code
|
||||
})
|
||||
console.log(list[0].bankName)
|
||||
if (list[0].bankName) {
|
||||
return list[0].bankName
|
||||
if (bank) {
|
||||
return bank.name
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
export function getBank(code) {
|
||||
if (code) {
|
||||
return bankListJson.find(item => {
|
||||
return item.code === code
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
export function getChildBank(pCode, cCode) {
|
||||
let bank = getBank(pCode)
|
||||
if (bank) {
|
||||
return bank.child.find(item => {
|
||||
return item.code === cCode
|
||||
})
|
||||
}
|
||||
}
|
||||
|
||||
@@ -312,8 +312,7 @@ import RsTop from '@/components/ebiz/agentEenter/RsTop'
|
||||
import { saveOrUpdateInfo, agentAll } from '@/api/ebiz/agentEenter/agentEenter.js'
|
||||
import { idToData } from '@/views/ebiz/customer/js/verification'
|
||||
import SelectBankName from '@/components/ebiz/account/SelectBankName'
|
||||
import getBankName from '@/components/ebiz/account/getBankName'
|
||||
import getBankCode from '@/components/ebiz/account/getBankCode'
|
||||
import { getChildBank, getBankName } from '@/components/ebiz/account/getBankName'
|
||||
import { getBankList } from '@/api/ebiz/sale/sale'
|
||||
import MinXin from '@/components/ebiz/account/mixins'
|
||||
import {
|
||||
@@ -551,8 +550,20 @@ export default {
|
||||
this.userInfo.sex = idToData(this.userInfo.idNo).sex
|
||||
}
|
||||
if (this.userInfo.bankName) {
|
||||
this.bankName = getBankName(this.bankList, this.userInfo.bankName)
|
||||
// 主行code
|
||||
this.code = this.userInfo.bankName
|
||||
// 主行名称
|
||||
this.bankName = getBankName(this.userInfo.bankName)
|
||||
}
|
||||
|
||||
if (this.userInfo.bankNum) {
|
||||
let bank = getChildBank(this.userInfo.bankName, this.userInfo.bankNum)
|
||||
this.$nextTick(() => {
|
||||
this.bankNum = bank.name
|
||||
})
|
||||
}
|
||||
|
||||
this.areaName = this.userInfo.bankAddress
|
||||
this.userInfo.nationality = 'CHN'
|
||||
}
|
||||
})
|
||||
|
||||
Reference in New Issue
Block a user