Commit d6200736ba2bd28207d7d3a0a87940a1b4fb59bf
1 parent
2cd0b0f44a
Exists in
master
登陆问题修复
Showing
1 changed file
with
6 additions
and
5 deletions
Show diff stats
src/pages/user/user.vue
... | ... | @@ -274,21 +274,22 @@ export default { |
274 | 274 | this.scrollTop = scrollTop |
275 | 275 | }, |
276 | 276 | onLoad() { |
277 | + const that = this | |
277 | 278 | // 判断是否授权 |
278 | 279 | uni.getSetting({ |
279 | 280 | success(res) { |
280 | 281 | console.log('authSetting', res.authSetting) |
281 | 282 | if (res.authSetting['scope.userInfo'] === true) { |
282 | - this.isAuth = true | |
283 | + that.isAuth = true | |
283 | 284 | } else { |
284 | - this.isAuth = false | |
285 | + that.isAuth = false | |
285 | 286 | } |
286 | 287 | }, |
287 | 288 | }) |
288 | 289 | store.dispatch('userRecommand/getRecommandList', { |
289 | - uid: this.$store.state.user.userInfo.uid, | |
290 | - openid: this.$store.state.user.userInfo.openid, | |
291 | - page: this.pagesnum, | |
290 | + uid: that.$store.state.user.userInfo.uid, | |
291 | + openid: that.$store.state.user.userInfo.openid, | |
292 | + page: that.pagesnum, | |
292 | 293 | }) |
293 | 294 | }, |
294 | 295 | onReachBottom() { | ... | ... |