修改bug

This commit is contained in:
zhouyanli
2026-06-09 14:20:46 +08:00
parent 87b5269b87
commit 94d03a270f
3 changed files with 21 additions and 7 deletions

View File

@@ -221,8 +221,8 @@ const handleLogin = () => {
if (res.data) {
uni.setStorageSync('token', res.data.token)
// 存用户ID
if (res.data.userId) {
uni.setStorageSync('userId', res.data.userId)
if (res.data.user.userId) {
uni.setStorageSync('userId', res.data.user.userId)
}
// 清掉上次账号的小区缓存,防止新账号显示旧小区
uni.removeStorageSync('currentVillage')