Browse Source

no message

featrue/v4.3
xpz2018 4 years ago
parent
commit
8eeb73165d
3 changed files with 15 additions and 5 deletions
  1. 2
      app.js
  2. 17
      pages/bank/create/index.js
  3. 1
      pages/home/authory/index.js

2
app.js

@ -1,7 +1,7 @@
//app.js //app.js
App({ App({
//----------------------------------------------globalData-------------------------------------- //----------------------------------------------globalData--------------------------------------
evn: 2,//0:开发环境,1:测试环境,2:生产环境
evn: 0,//0:开发环境,1:测试环境,2:生产环境
tmplIds: ['SUjEgwDopCv9xkkSZ4KbS0L7XbAiVQor6GmPg14K760'], tmplIds: ['SUjEgwDopCv9xkkSZ4KbS0L7XbAiVQor6GmPg14K760'],
agentMsgIds: ['kG8DErWDpyzBHCFaLlSKYMF7xVy8UpgogCwV_WSNt10', 'lOQ8Gvyy_dTk68bYGpRVnVA0M7DsYYrV81Gd39GUPBA'], agentMsgIds: ['kG8DErWDpyzBHCFaLlSKYMF7xVy8UpgogCwV_WSNt10', 'lOQ8Gvyy_dTk68bYGpRVnVA0M7DsYYrV81Gd39GUPBA'],
version: 152, version: 152,

17
pages/bank/create/index.js

@ -1,6 +1,7 @@
// pages/bank/edit/index.js // pages/bank/edit/index.js
import { getBankcardInfo, ocrBankcard, verifyBankcard } from "../../api/payment" import { getBankcardInfo, ocrBankcard, verifyBankcard } from "../../api/payment"
import { postCaptcha } from "../../api/user" import { postCaptcha } from "../../api/user"
import { getBaseInfo } from "../../api/ztb"
const util = require('../../../utils/util') const util = require('../../../utils/util')
import { $wuxCountDown } from '../../../components/index' import { $wuxCountDown } from '../../../components/index'
const app = getApp() const app = getApp()
@ -33,10 +34,18 @@ Page({
* 生命周期函数--监听页面加载 * 生命周期函数--监听页面加载
*/ */
onLoad: function (options) { 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 })
}
}, },
/** /**

1
pages/home/authory/index.js

@ -50,6 +50,7 @@ Page({
certificateIdentity(this.data.form).then(res => { certificateIdentity(this.data.form).then(res => {
wx.hideLoading() wx.hideLoading()
app.globalData.userInfo.isAuth = 1 app.globalData.userInfo.isAuth = 1
app.globalData.userInfo.realName = this.data.form.realName
this.data.auth = true this.data.auth = true
this.wuxDialog = this.wuxDialog || this.selectComponent('#wux-dialog') this.wuxDialog = this.wuxDialog || this.selectComponent('#wux-dialog')
this.wuxDialog.open({ this.wuxDialog.open({

Loading…
Cancel
Save