From b8ed24ee4c9c8a7ca518d30dc0ad84e82de36bac Mon Sep 17 00:00:00 2001 From: why <986973311@qq.com> Date: Tue, 1 Aug 2023 09:48:43 +0800 Subject: [PATCH] 1 --- pages/login/index.vue | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/pages/login/index.vue b/pages/login/index.vue index e95bfeb..ce013cf 100644 --- a/pages/login/index.vue +++ b/pages/login/index.vue @@ -92,7 +92,9 @@ } this.$http.post("/blade-auth/oauth/token",param,headers).then((res)=>{ + // console.log(res) this.saveLocal(res) + if(res.role_name == 'CUSTOMER_USER'){ //单位管理员 uni.redirectTo({ @@ -131,7 +133,9 @@ uni.setStorageSync("role_id",res.role_id) uni.setStorageSync("role_name",res.role_name) uni.setStorageSync("tenant_id",res.tenant_id) - uni.setStorageSync("regionId",res.detail.otherInfo.regionId) + if(res.role_name == 'SUPERVISE_USER'){ + uni.setStorageSync("regionId",res.detail.otherInfo.regionId) + } } } }