个人中心修改密码 & 会员个人信息
This commit is contained in:
@@ -1,8 +1,14 @@
|
||||
import type { ApiResponse } from "@/lib/api"
|
||||
import type { UserItem, UserQueryParams } from "@/lib/models/user"
|
||||
import type {
|
||||
PhpUserModel,
|
||||
UpdateUserInfoParams,
|
||||
UpdateUserPwdParams,
|
||||
UserItem,
|
||||
UserQueryParams,
|
||||
} from "@/lib/models/user"
|
||||
import { callByUser, callPublic } from "./base"
|
||||
|
||||
// ==================== 用户管理(.NET /api/baseinfo/v1/user/*) ====================
|
||||
// ==================== 用户管理 ====================
|
||||
|
||||
export async function fetchUserPage(
|
||||
params: UserQueryParams,
|
||||
@@ -43,21 +49,16 @@ export async function updateUserProfile(
|
||||
)
|
||||
}
|
||||
|
||||
// ==================== 个人中心资料/密码(.NET /user/*,cookie 会话) ====================
|
||||
// ==================== 个人中心资料/密码 ====================
|
||||
|
||||
export async function updateUserInfo(data: {
|
||||
QQ: string
|
||||
Wx: string
|
||||
// TaoBao: string
|
||||
Email: string
|
||||
}): Promise<ApiResponse<undefined>> {
|
||||
return await callPublic<undefined>("/user/UpdateInfo", data)
|
||||
export async function updateUserInfo(
|
||||
data: UpdateUserInfoParams,
|
||||
): Promise<ApiResponse<undefined>> {
|
||||
return await callPublic<undefined>("/user/ApiUpdateInfo", data)
|
||||
}
|
||||
|
||||
export async function updateUserPwd(data: {
|
||||
OldPwd: string
|
||||
NewPwd: string
|
||||
ConfirmPwd: string
|
||||
}): Promise<ApiResponse<undefined>> {
|
||||
return await callPublic<undefined>("/user/UpdatePwd", data)
|
||||
export async function updateUserPwd(
|
||||
data: UpdateUserPwdParams,
|
||||
): Promise<ApiResponse<PhpUserModel>> {
|
||||
return await callPublic<PhpUserModel>("/user/UpdatePwd", data)
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user