From e4dbf13e917784f0e690709e2dd405e7475a86a1 Mon Sep 17 00:00:00 2001 From: liudong <liudong> Date: 星期五, 16 八月 2024 12:08:07 +0800 Subject: [PATCH] 新版UI对话页面开发 --- src/store/modules/user/index.ts | 5 ++++- 1 files changed, 4 insertions(+), 1 deletions(-) diff --git a/src/store/modules/user/index.ts b/src/store/modules/user/index.ts index faa226d..7bb51c3 100644 --- a/src/store/modules/user/index.ts +++ b/src/store/modules/user/index.ts @@ -76,7 +76,10 @@ name: res.data.nickname, email: res.data.email, }; - this.resources=res.data.resources; + if(res.data.roles && res.data.roles.length>0) + this.resources=res.data.roles[0].resources; + else + this.resources=res.data.resources; setUserInfo(JSON.stringify(userInfo)); setUserResources(JSON.stringify(this.resources)) for (const r of this.resources) { -- Gitblit v1.8.0