Commit caaa755c authored by 李晓兵's avatar 李晓兵

'修改银行卡逻辑'

parent 785bc27d
......@@ -305,30 +305,41 @@ export default {
this.getinvoiceList()
},
methods: {
verified () {
this.saveWord()
async verified () {
let bpId = await this.saveWord()
this.getBankInfo()
},
saveProtocol () {
async saveProtocol () {
let vm = this
let url = process.env.basePath + 'bp_np_bind_save'
let param = {
master: this.baseInfo,
}
vm.hlsPopup.showLoading('保存中!')
vm.hlsHttp.post(url, param).then(function (res) {
let res = await vm.hlsHttp.post(url, param)
if (res.result === 'S') {
vm.hlsPopup.showSuccess('保存成功')
vm.isSave = true
window.localStorage.setItem('user_id', res.bp_id)
window.sessionStorage.setItem('user_id', res.bp_id)
window.sessionStorage.setItem('bp_name', vm.baseInfo.bp_name)
window.localStorage.setItem('bp_name', vm.baseInfo.bp_name)
return res.bp_id
}
/* vm.hlsHttp.post(url, param).then(function (res) {
vm.hlsPopup.hideLoading()
if (res.result === 'S') {
vm.hlsPopup.showSuccess('保存成功')
vm.isSave = true
return res.bp_id
window.localStorage.setItem('user_id', res.bp_id)
window.sessionStorage.setItem('user_id', res.bp_id)
window.sessionStorage.setItem('bp_name', vm.baseInfo.bp_name)
window.localStorage.setItem('bp_name', vm.baseInfo.bp_name)
}
})
})*/
},
saveWord () {
async saveWord () {
let vm = this
if (!vm.baseInfo.bp_type) {
vm.hlsPopup.showLongCenter('客户类型不能为空!')
......@@ -361,7 +372,8 @@ export default {
} else if (!vm.hlsUtil.phoneNumber(vm.baseInfo.phone)) {
vm.hlsPopup.showLongCenter('手机号码有误!')
} else {
vm.saveProtocol()
let bpId = await vm.saveProtocol()
return bpId
}
},
uploadIdCardFront () {
......@@ -502,7 +514,7 @@ export default {
vm.hlsPopup.hideLoading()
if (res.result === 'S') {
vm.successCall()
this.hlsPopup.showLongCenter('保存成功')
vm.hlsPopup.showLongCenter('保存成功')
setTimeout(vm.successCall, 2000)
}
})
......
......@@ -133,7 +133,7 @@ export function get (url) {
}
// post请求
export function post (url, param) {
param.user_id = window.localStorage.user_id
// param.user_id = window.localStorage.user_id
param.access_token = window.localStorage.access_token
let headers = {}
if (window.localStorage.access_token) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment