This commit is contained in:
浅念
2025-12-22 11:41:23 +08:00
parent 5316a23385
commit 1b04abc3b4
328 changed files with 75051 additions and 0 deletions
+96
View File
@@ -0,0 +1,96 @@
import request from '@/utils/http'
export class UserService {
//获取公司
static getCompanyList() {
return request.get<Api.Brand.BrandInfo>({
url: '/common/preset/corps'
})
}
//获取系统
static getsystemsList() {
return request.get<Api.Brand.BrandInfo>({
url: '/common/preset/systems'
})
}
//注册
static register(params: any) {
return request.post<Api.Auth.registerResponse>({
url: '/common/auth/register',
params
// showErrorMessage: false // 不显示错误消息
})
}
//获取 飞书信息
static getfeishuAppList(params: any) {
return request.get<Api.Brand.BrandInfo>({
url: '/common/preset/feishu/app',
params
})
}
// 登录
static login(params: Api.Auth.LoginParams) {
return request.post<Api.Auth.LoginResponse>({
url: '/common/auth/login',
params
// showErrorMessage: false // 不显示错误消息
})
}
// 刷新token
static refreshToken(params: { refresh_token: string }) {
return request.post<any>({
url: '/common/auth/refresh/token',
params
})
}
//飞书凭证
static getfeishuscope() {
return request.get<Api.Auth.Authfeishuscope>({
url: '/common/auth/feishu/scope'
})
}
// 获取用户信息
static getUserInfo() {
return request.get<Api.User.UserInfo>({
url: '/common/user/info'
})
}
// 获取用户列表
static getUserList(params: Api.Common.PaginatingParams) {
return request.get<Api.User.UserListData>({
url: '/api/user/list',
params
})
}
//角色 列表
static getRoleList(params: Api.Common.PaginatingParams) {
return request.get<Api.Role.RoleListData>({
url: '/admin/role/list',
params
})
}
//获取菜单
static getMenuList() {
return request.get<Api.User.UserInfo>({
url: '/common/preset/menus'
})
}
//个人信息编辑
static editUserInfo(params: any) {
return request.post<Api.Work.AddResponse>({
url: '/admin/user/edit',
params
})
}
//修改密码 crm/user/savePassword
static savePassword(params: any) {
return request.post<Api.Work.AddResponse>({
url: '/admin/user/update/password',
params
// showErrorMessage: false // 不显示错误消息
})
}
}