import request from '@/utils/request.js'

export const getCodeImg = () => {
    return request({
        url: '/auth/captchaImage',
        method: 'get'
    })
}


export const login = (data) => {
    return request({
        url: '/auth/login',
        method: 'post',
        data
    })
}
export const switchAccount = (userId) => {
    return request({
        url: `/auth/switch/account/${userId}`,
        method: 'post',
    })
}

export const getUserInfo = () => {
    return request({
        url: '/auth/info',
        method: 'get',
    })
}
export const getAuthInfo = () => {
    return request({
        url: '/admin/mosr/user/detail/info',
        method: 'get',
    })
}
