更改登录流程

This commit is contained in:
魏啾
2024-05-27 14:24:11 +08:00
parent 8386120c87
commit 72be3befa7
3 changed files with 38 additions and 14 deletions

View File

@@ -276,11 +276,13 @@
if (e.q) {
this.tableCode = this.getQueryString(decodeURIComponent(e.q), 'code')
uni.cache.set('tableCode', this.tableCode)
this.scanCodehandle()
// this.scanCodehandle()
uni.pro.navigateTo('login/login', {
type: 0
})
} else {
this.tableCode = e.tableCode
uni.cache.set('tableCode', this.tableCode)
this.productqueryShopIdByTableCode()//获取shop User id
this.tableCode = uni.cache.get('tableCode')
this.productqueryShopIdByTableCode() //获取shop User id
}
uni.$on('message', this.getMessage)
@@ -293,6 +295,11 @@
this.socketTicket.Close()
uni.$off('message')
},
onShow() {
if (uni.cache.get('token')) {
this.productqueryShopIdByTableCode() //获取shop User id
}
},
methods: {
// 单独获取他的shopUserid
async productqueryShopIdByTableCode() {
@@ -399,7 +406,6 @@
}
},
scanCodehandle(e) {
// #ifdef MP-WEIXIN || MP-ALIPAY
uni.login({ //alipay weixin
provider: 'weixin',