|
|
|
@ -1,6 +1,7 @@ |
|
|
|
// pages/bank/edit/index.js
|
|
|
|
import { getBankcardInfo, ocrBankcard, verifyBankcard } from "../../api/payment" |
|
|
|
import { postCaptcha } from "../../api/user" |
|
|
|
import { getBaseInfo } from "../../api/ztb" |
|
|
|
const util = require('../../../utils/util') |
|
|
|
import { $wuxCountDown } from '../../../components/index' |
|
|
|
const app = getApp() |
|
|
|
@ -33,10 +34,18 @@ Page({ |
|
|
|
* 生命周期函数--监听页面加载 |
|
|
|
*/ |
|
|
|
onLoad: function (options) { |
|
|
|
this.setData({ |
|
|
|
userInfo: app.globalData.userInfo, |
|
|
|
['form.name']: app.globalData.userInfo.realName |
|
|
|
}) |
|
|
|
if(util.isEmpty(app.globalData.userInfo.realName)){ |
|
|
|
wx.showLoading({ title: '加载中', mask: true }) |
|
|
|
getBaseInfo().then(result => { |
|
|
|
app.globalData.userInfo = result.data |
|
|
|
this.setData({ userInfo: app.globalData.userInfo, ['form.name']: app.globalData.userInfo.realName }) |
|
|
|
wx.hideLoading() |
|
|
|
}).catch(err => { |
|
|
|
wx.hideLoading() |
|
|
|
}) |
|
|
|
} else { |
|
|
|
this.setData({ userInfo: app.globalData.userInfo, ['form.name']: app.globalData.userInfo.realName }) |
|
|
|
} |
|
|
|
}, |
|
|
|
|
|
|
|
/** |
|
|
|
|