bug修改
This commit is contained in:
+19
-7
@@ -115,7 +115,10 @@ Page({
|
||||
url: '../home/home',
|
||||
})
|
||||
wx.setStorageSync('authorize', true) // 设置有过微信授权
|
||||
wx.setStorageSync('avatarUrl', that.data.userInfoTemp.avatarUrl)
|
||||
wx.setStorage({
|
||||
key: 'avatarUrl',
|
||||
data: result.avatarUrl
|
||||
})
|
||||
}else{ // 首次登录不能直接用微信快捷登录
|
||||
wx.showToast({
|
||||
title: '暂无授权手机号',
|
||||
@@ -267,7 +270,21 @@ Page({
|
||||
UserApi.wxBind(params).then(res=>{})
|
||||
})
|
||||
},
|
||||
onLoad(){
|
||||
// onLoad(){
|
||||
// const that = this
|
||||
// wx.getStorage({
|
||||
// key: 'userInfoTemp',
|
||||
// success(res){
|
||||
// that.setData({
|
||||
// userInfoTemp: res.data
|
||||
// })
|
||||
// }
|
||||
// })
|
||||
// },
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {
|
||||
const that = this
|
||||
wx.getStorage({
|
||||
key: 'userInfoTemp',
|
||||
@@ -277,11 +294,6 @@ Page({
|
||||
})
|
||||
}
|
||||
})
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
*/
|
||||
onShow: function () {
|
||||
UserApi.getRSAPublicKey().then(res => {
|
||||
if (res.success) {
|
||||
this.setData({
|
||||
|
||||
Reference in New Issue
Block a user