Commit ebedcd0d by huangzhi

feat: 登出

parent a3b45a58
...@@ -209,11 +209,19 @@ export default { ...@@ -209,11 +209,19 @@ export default {
// 退出登录 // 退出登录
handleLogoutConfirm() { handleLogoutConfirm() {
this.logoutVisible = false this.logoutVisible = false
this.handleLogout()
this.$store.commit('user/setUserInfo', {}) this.$store.commit('user/setUserInfo', {})
this.$store.commit('user/setCode', '') this.$store.commit('user/setCode', '')
this.$store.commit('user/setUid', '') this.$store.commit('user/setUid', '')
this.$store.commit('user/setAccessToken', '') this.$store.commit('user/setAccessToken', '')
}, },
// 退出登录
handleLogout() {
const url = `${hostPrefix}/h5-course/wxLogout`
uni.navigateTo({
url: `/pages/web/web?title=退出登录&loadUrl=${encodeURIComponent(url)}`,
})
},
// 跳转订单 // 跳转订单
navigateToOrder() { navigateToOrder() {
// const aa = // const aa =
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment