Explorar el Código

修改判断逻辑

lex-wxl hace 1 mes
padre
commit
776b74e10e
Se han modificado 1 ficheros con 1 adiciones y 2 borrados
  1. 1 2
      src/store/modules/user.ts

+ 1 - 2
src/store/modules/user.ts

@@ -116,8 +116,7 @@ function handleUserInfo(userType: rolesType, userInfo: Record<string, any>) {
       realName = userInfo.realName
       phone = userInfo.phone
       subjectId = userInfo.subjectId
-      // userInfo.userVip?.vipType === 'NOT_VIP' || !userInfo.userVip?.vipType ||
-      isVip = userInfo.userVip ? false : userInfo.userVip?.vipType === "NOT_VIP" || !userInfo.userVip?.vipType ? true : false
+      isVip = userInfo.userVip ? (userInfo.userVip?.vipType === "NOT_VIP" || !userInfo.userVip?.vipType ? true : false) : false
    } else {
       avatar = userInfo.avatar
       username = userInfo.nickname