1. 统一化代码

2. 增加 DocAlert 关联文档
This commit is contained in:
YunaiV
2023-04-05 20:13:35 +08:00
parent bb88e3d77c
commit 4404554cfc
111 changed files with 640 additions and 567 deletions

View File

@ -17,7 +17,7 @@ export interface SmsLoginVO {
}
// 登录
export const loginApi = (data: UserLoginVO) => {
export const login = (data: UserLoginVO) => {
return request.post({ url: '/system/auth/login', data })
}
@ -27,47 +27,47 @@ export const refreshToken = () => {
}
// 使用租户名,获得租户编号
export const getTenantIdByNameApi = (name: string) => {
export const getTenantIdByName = (name: string) => {
return request.get({ url: '/system/tenant/get-id-by-name?name=' + name })
}
// 登出
export const loginOutApi = () => {
export const loginOut = () => {
return request.post({ url: '/system/auth/logout' })
}
// 获取用户权限信息
export const getInfoApi = () => {
export const getInfo = () => {
return request.get({ url: '/system/auth/get-permission-info' })
}
// 路由
export const getAsyncRoutesApi = () => {
export const getAsyncRoutes = () => {
return request.get({ url: '/system/auth/list-menus' })
}
//获取登录验证码
export const sendSmsCodeApi = (data: SmsCodeVO) => {
export const sendSmsCode = (data: SmsCodeVO) => {
return request.post({ url: '/system/auth/send-sms-code', data })
}
// 短信验证码登录
export const smsLoginApi = (data: SmsLoginVO) => {
export const smsLogin = (data: SmsLoginVO) => {
return request.post({ url: '/system/auth/sms-login', data })
}
// 社交授权的跳转
export const socialAuthRedirectApi = (type: number, redirectUri: string) => {
export const socialAuthRedirect = (type: number, redirectUri: string) => {
return request.get({
url: '/system/auth/social-auth-redirect?type=' + type + '&redirectUri=' + redirectUri
})
}
// 获取验证图片 以及token
export const getCodeApi = (data) => {
// 获取验证图片以及 token
export const getCode = (data) => {
return request.postOriginal({ url: 'system/captcha/get', data })
}
// 滑动或者点选验证
export const reqCheckApi = (data) => {
export const reqCheck = (data) => {
return request.postOriginal({ url: 'system/captcha/check', data })
}