protable组件抽取,并绘制demo界面

This commit is contained in:
2024-10-15 15:37:50 +08:00
parent 9957857be0
commit 7c8d5644f7
18 changed files with 628 additions and 156 deletions

View File

@@ -0,0 +1,26 @@
import { Login } from './interface'
import { ADMIN as rePrefix } from '@/api/config/serviceName'
import http from '@/api'
/**
* @name 登录模块
*/
// 用户登录
export const loginApi = (params: Login.ReqLoginForm) => {
return http.post<Login.ResLogin>(`${rePrefix}/login`, params, { loading: false })
}
// 获取菜单列表
export const getAuthMenuListApi = () => {
return http.get<Menu.MenuOptions[]>(`${rePrefix}/menu/list`, {}, { loading: false })
}
// 获取按钮权限
export const getAuthButtonListApi = () => {
return http.get<Login.ResAuthButtons>(`${rePrefix}/auth/buttons`, {}, { loading: false })
}
// 用户退出登录
export const logoutApi = () => {
return http.post(`${rePrefix}/logout`)
}