@@ -235,7 +235,7 @@ const submit = async () => {
// await useUserStore.getUserInfo()
// 若是扫码登录且账号未注册的,注册后需授权给pc登录
- if (wxLoginCode)handleWeiXinQrCodeAuthorize()
+ if (wxLoginCode) handleWeiXinQrCodeAuthorize()
} catch (err) {
uni.showToast({ title: err?.msg || '保存失败', icon: 'none' })
}
@@ -55,7 +55,8 @@ export const userStore = defineStore('user', {
this.phone = query.phone
const apiList = [weChatLogin, smsLogin, passwordLogin]
const { data, code } = await apiList[index](query)
- if (code === 0) {
+ // 扫码登录不需要弹提示语
+ if (code === 0 && !uni.getStorageSync('wxLoginCode')) {
uni.showToast({
title: '登录成功'
})