feat : 用户账号切换

This commit is contained in:
clay
2024-06-19 01:26:24 +08:00
parent 5410b6d248
commit 59014f6367
3 changed files with 47 additions and 2 deletions

View File

@@ -7,6 +7,7 @@ export const getCodeImg = () => {
})
}
export const login = (data) => {
return request({
url: '/auth/login',
@@ -14,6 +15,12 @@ export const login = (data) => {
data
})
}
export const switchAccount = (userId) => {
return request({
url: `/auth/switch/account/${userId}`,
method: 'post',
})
}
export const getUserInfo = () => {
return request({

View File

@@ -15,6 +15,12 @@ export const getSubCompOpt = () => {
method: 'get'
})
}
export const getUserAccount = () => {
return request({
url: `/admin/mosr/user/account/list`,
method: 'get'
})
}
// 查询角色信息
export const getRolesOpt = () => {