| | |
| | | }, |
| | | |
| | | loginWx() { |
| | | var that = this |
| | | if (!this.waitAgree()) return |
| | | |
| | | if (app.globalData.userProfile) { |
| | | this.loginPw(app.globalData.userProfile) |
| | | wx.requestSubscribeMessage({ |
| | | tmplIds: [ |
| | | '6JQFOJ12yBvKfRg_duSdwKiH5_J3LpICmz3Li-L1Cr8', |
| | | 'zPNMzF5WsshniJyl83DD-lDZtNvx7JyqLbKgqDl0qvU', |
| | | 'dqREi7vAd03OOirTgBGcm5aCihZJKBjVpiA8Kbu4B8w' |
| | | ], |
| | | success(res) { |
| | | console.log(res); |
| | | }, |
| | | fail(e) { |
| | | console.log(fail); |
| | | }, |
| | | complete() { |
| | | that.loginPw(app.globalData.userProfile) |
| | | } |
| | | }) |
| | | }else { |
| | | wx.getUserProfile({ |
| | | lang: 'zh_CN', |
| | |
| | | key: 'userProfile', |
| | | }) |
| | | this.loginPw(res.userInfo) |
| | | }, |
| | | complete() { |
| | | wx.requestSubscribeMessage({ |
| | | tmplIds: [ |
| | | '6JQFOJ12yBvKfRg_duSdwKiH5_J3LpICmz3Li-L1Cr8', |
| | | 'zPNMzF5WsshniJyl83DD-lDZtNvx7JyqLbKgqDl0qvU', |
| | | 'dqREi7vAd03OOirTgBGcm5aCihZJKBjVpiA8Kbu4B8w' |
| | | ], |
| | | success(res) { |
| | | console.log(res); |
| | | }, |
| | | fail(e) { |
| | | console.log(e); |
| | | }, |
| | | complete() { |
| | | } |
| | | }) |
| | | } |
| | | }) |
| | | } |
| | |
| | | return true |
| | | } else { |
| | | wx.showToast({ |
| | | title: '请先同意说明', |
| | | title: '阅读并同意条款', |
| | | icon: 'none' |
| | | }) |
| | | return false |