Showing
4 changed files
with
4 additions
and
5 deletions
@@ -327,7 +327,8 @@ App({ | @@ -327,7 +327,8 @@ App({ | ||
327 | }, | 327 | }, |
328 | 328 | ||
329 | isLogin: function () { | 329 | isLogin: function () { |
330 | - return this.globalData.userInfo.uid > 0; | 330 | + let uid = this.getUid(); |
331 | + return uid > 0; | ||
331 | }, | 332 | }, |
332 | 333 | ||
333 | getUid: function () { | 334 | getUid: function () { |
@@ -62,7 +62,6 @@ export const getPhoneNumber = async (e) => { | @@ -62,7 +62,6 @@ export const getPhoneNumber = async (e) => { | ||
62 | throw new Error('手机号获取失败,请使用手机号登录'); | 62 | throw new Error('手机号获取失败,请使用手机号登录'); |
63 | } | 63 | } |
64 | const bindResult = await login.bindMiniAppByAuto(union_id, phoneNumber, countryCode); | 64 | const bindResult = await login.bindMiniAppByAuto(union_id, phoneNumber, countryCode); |
65 | - console.log(bindResult); | ||
66 | if (bindResult && bindResult.is_register === 0) { | 65 | if (bindResult && bindResult.is_register === 0) { |
67 | const newUserInfo = { | 66 | const newUserInfo = { |
68 | is_bind: bindResult.is_bind, | 67 | is_bind: bindResult.is_bind, |
@@ -431,14 +431,14 @@ redirectAction: function() { | @@ -431,14 +431,14 @@ redirectAction: function() { | ||
431 | let that = this; | 431 | let that = this; |
432 | if (that.data.h5back) { | 432 | if (that.data.h5back) { |
433 | wx.navigateBack({ | 433 | wx.navigateBack({ |
434 | - delta: 2, | 434 | + delta: 1, |
435 | }) | 435 | }) |
436 | wx.redirectTo({ | 436 | wx.redirectTo({ |
437 | url: '../webview/webview?url=' + that.data.h5back | 437 | url: '../webview/webview?url=' + that.data.h5back |
438 | }) | 438 | }) |
439 | } else { | 439 | } else { |
440 | wx.navigateBack({ | 440 | wx.navigateBack({ |
441 | - delta: 2, | 441 | + delta: 1, |
442 | }) | 442 | }) |
443 | return | 443 | return |
444 | } | 444 | } |
-
Please register or login to post a comment