mirror of
https://gitee.com/xiaonuobase/snowy.git
synced 2026-03-22 10:47:16 +08:00
获取当前用户信息,赋值给对应的组织架构树
This commit is contained in:
@@ -22,7 +22,13 @@
|
||||
import userCenterApi from '@/api/sys/userCenterApi'
|
||||
let data = ref({})
|
||||
userCenterApi.userLoginOrgTree().then((res) => {
|
||||
data.value = res[0]
|
||||
const userInfo = tool.data.get('USER_INFO')
|
||||
res = Array.from(res)
|
||||
res.forEach((item) => {
|
||||
if (item.id === userInfo.orgId) {
|
||||
data.value = item
|
||||
}
|
||||
})
|
||||
})
|
||||
</script>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user