mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-07 07:46:43 +08:00
反显修改
This commit is contained in:
11
src/components/ebiz/account/getBankCode.js
Normal file
11
src/components/ebiz/account/getBankCode.js
Normal file
@@ -0,0 +1,11 @@
|
||||
export default function getBankCode(data, bankName) {
|
||||
if (bankName) {
|
||||
let list = data.filter(item => {
|
||||
return item.bankName == bankName
|
||||
})
|
||||
console.log(list[0].code, 'list[0].code')
|
||||
if (list[0].code) {
|
||||
return list[0].code
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,7 +1,12 @@
|
||||
import { getBankList } from '@/api/ebiz/sale/sale'
|
||||
export default function getBankName(data, code) {
|
||||
if (code) {
|
||||
return data.filter(item => {
|
||||
let list = data.filter(item => {
|
||||
return item.code == code
|
||||
})[0].bankName
|
||||
})
|
||||
console.log(list[0].bankName)
|
||||
if (list[0].bankName) {
|
||||
return list[0].bankName
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
28
src/components/ebiz/account/mixins.js
Normal file
28
src/components/ebiz/account/mixins.js
Normal file
@@ -0,0 +1,28 @@
|
||||
import { getBankList } from '@/api/ebiz/sale/sale'
|
||||
const myMixin = {
|
||||
data() {
|
||||
return {
|
||||
bankList: [] //银行名称列表
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
getBankList() {
|
||||
let data = {
|
||||
operateType: this.operateType
|
||||
}
|
||||
getBankList(data).then(res => {
|
||||
if (res.result == '0') {
|
||||
this.bankList = res.content
|
||||
this.bankList1 = res.content
|
||||
} else {
|
||||
this.$toast(res.resultMessage)
|
||||
}
|
||||
})
|
||||
}
|
||||
},
|
||||
created() {
|
||||
console.log('1111111111111')
|
||||
this.getBankList()
|
||||
}
|
||||
}
|
||||
export default myMixin
|
||||
@@ -282,13 +282,7 @@
|
||||
<p class="fs14 mt5 ml5">注:是否确认提交,一旦提交在人管审批之前无法再次进行修改</p>
|
||||
</van-dialog>
|
||||
<!--开户银行选择-->
|
||||
<SelectBankName
|
||||
:inputShow="inputShow"
|
||||
:listShow.sync="islistShow"
|
||||
:operateType="'enter_bank_type'"
|
||||
@getBankList="getBankList"
|
||||
@getBank="getBank"
|
||||
></SelectBankName>
|
||||
<SelectBankName :inputShow="inputShow" :listShow.sync="islistShow" :operateType="'enter_bank_type'" @getBank="getBank"></SelectBankName>
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
@@ -309,6 +303,9 @@ import { saveOrUpdateInfo, agentAll } from '@/api/ebiz/agentEenter/agentEenter.j
|
||||
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 { getBankList } from '@/api/ebiz/sale/sale'
|
||||
import MinXin from '@/components/ebiz/account/mixins'
|
||||
import {
|
||||
selectComp,
|
||||
// appCallBack,
|
||||
@@ -325,6 +322,7 @@ import {
|
||||
|
||||
export default {
|
||||
name: 'insuredInfo',
|
||||
mixins: MinXin,
|
||||
components: {
|
||||
SelectBankName, //开户银行弹窗
|
||||
[SelectRadio.name]: SelectRadio,
|
||||
@@ -451,6 +449,9 @@ export default {
|
||||
}
|
||||
}
|
||||
},
|
||||
created() {
|
||||
this.getBankList()
|
||||
},
|
||||
mounted() {
|
||||
// 筛选按钮的点击事件
|
||||
// window.appCallBack = this.appCallBack
|
||||
@@ -458,12 +459,21 @@ export default {
|
||||
this.agentAll()
|
||||
},
|
||||
methods: {
|
||||
getBankList(value) {
|
||||
//获取银行列表
|
||||
this.bankList = value
|
||||
|
||||
console.log('getBankList', value)
|
||||
// 获取银行卡列表
|
||||
getBankList() {
|
||||
let data = {
|
||||
operateType: 'enter_bank_type'
|
||||
}
|
||||
getBankList(data).then(res => {
|
||||
if (res.result == '0') {
|
||||
this.bankList = res.content
|
||||
this.bankList1 = res.content
|
||||
} else {
|
||||
this.$toast(res.resultMessage)
|
||||
}
|
||||
})
|
||||
},
|
||||
|
||||
getBank(bank) {
|
||||
//获取银行名称
|
||||
this.userInfo.bankName = bank.bankName
|
||||
@@ -492,8 +502,10 @@ export default {
|
||||
this.userInfo.age = idToData(this.userInfo.idNo).age
|
||||
this.userInfo.sex = idToData(this.userInfo.idNo).sex
|
||||
}
|
||||
this.userInfo.bankName = getBankName(this.bankList, this.userInfo.bankName)
|
||||
console.log('getBankName', getBankName(this.bankList, this.userInfo.bankName))
|
||||
if (this.userInfo.bankName) {
|
||||
this.userInfo.bankName = getBankName(this.bankList, this.userInfo.bankName)
|
||||
}
|
||||
|
||||
this.userInfo.nationality = 'CHN'
|
||||
}
|
||||
})
|
||||
@@ -563,7 +575,7 @@ export default {
|
||||
// if (this.userInfo.bankName == '工商银行') {
|
||||
// this.userInfo.bankName = '102'
|
||||
// }
|
||||
this.userInfo.bankName = this.code
|
||||
this.userInfo.bankName = getBankCode(this.bankList, this.userInfo.bankName)
|
||||
if (
|
||||
//学历为初中、小学、其他、文盲阻断入司
|
||||
Number(this.userInfo.degree) == 13 ||
|
||||
|
||||
Reference in New Issue
Block a user