Merge branch 'feature/bpm_fix_250121' of https://github.com/zws-code/yudao-ui-admin-vue3-fix into feature/bpm
This commit is contained in:
@ -16,6 +16,7 @@ interface UserVO {
|
||||
interface UserInfoVO {
|
||||
// USER 缓存
|
||||
permissions: string[]
|
||||
permissionsSet: Set<string>
|
||||
roles: string[]
|
||||
isSetUser: boolean
|
||||
user: UserVO
|
||||
@ -24,6 +25,7 @@ interface UserInfoVO {
|
||||
export const useUserStore = defineStore('admin-user', {
|
||||
state: (): UserInfoVO => ({
|
||||
permissions: [],
|
||||
permissionsSet: new Set<string>(),
|
||||
roles: [],
|
||||
isSetUser: false,
|
||||
user: {
|
||||
@ -58,6 +60,7 @@ export const useUserStore = defineStore('admin-user', {
|
||||
userInfo = await getInfo()
|
||||
}
|
||||
this.permissions = userInfo.permissions
|
||||
this.permissionsSet = new Set(userInfo.permissions)
|
||||
this.roles = userInfo.roles
|
||||
this.user = userInfo.user
|
||||
this.isSetUser = true
|
||||
|
||||
Reference in New Issue
Block a user