|
@@ -300,13 +300,24 @@ Component({
|
|
|
},
|
|
},
|
|
|
authorizedLogin(e) {
|
|
authorizedLogin(e) {
|
|
|
const that = this;
|
|
const that = this;
|
|
|
- if (e.detail.userInfo) {
|
|
|
|
|
|
|
+ if (e?.detail?.userInfo) {
|
|
|
// 用户点击允许,获取到用户信息
|
|
// 用户点击允许,获取到用户信息
|
|
|
this.setData({
|
|
this.setData({
|
|
|
showLoading: true,
|
|
showLoading: true,
|
|
|
disableCommitBtn: true,
|
|
disableCommitBtn: true,
|
|
|
});
|
|
});
|
|
|
|
|
|
|
|
|
|
+ console.log("authorizedLogin=>"+{
|
|
|
|
|
+ token: wx.getStorageSync("token") || token_empower,
|
|
|
|
|
+ unionid: wx.getStorageSync("unionid"),
|
|
|
|
|
+ openid: wx.getStorageSync("openid"),
|
|
|
|
|
+ avatarUrl: that.data.avatarUrl,
|
|
|
|
|
+ nickname: that.data.nickName,
|
|
|
|
|
+ encryptphone: that.data.encryptphone,
|
|
|
|
|
+ longandlat: that.data.longitude + "|" + that.data.latitude
|
|
|
|
|
+ });
|
|
|
|
|
+
|
|
|
|
|
+
|
|
|
wx.request({
|
|
wx.request({
|
|
|
url: `${homeApi_empower}/wxlogin`,
|
|
url: `${homeApi_empower}/wxlogin`,
|
|
|
data: {
|
|
data: {
|