feat: app功能基本实现

This commit is contained in:
gin
2026-05-26 11:54:24 +08:00
parent 2757a4fb49
commit 2a702fa6a9
218 changed files with 6766 additions and 5961 deletions
+32
View File
@@ -0,0 +1,32 @@
import { request } from '@/utils/http'
import type { UserInfoDTO } from './types'
export interface UserProfileDTO {
user: UserInfoDTO
roleName?: string
}
export interface UpdateProfileCommand {
nickName?: string
phoneNumber?: string
email?: string
sex?: number
}
export interface UpdatePasswordCommand {
newPassword: string
confirmPassword: string
}
export function getProfileApi() {
return request<UserProfileDTO>({ method: 'GET', url: '/app/user/profile' })
}
export function updateProfileApi(data: UpdateProfileCommand) {
return request<void>({ method: 'PUT', url: '/app/user/profile', data })
}
export function updatePasswordApi(data: UpdatePasswordCommand) {
return request<void>({ method: 'PUT', url: '/app/user/profile/password', data })
}