fix: 用户js对应bug修复。

This commit is contained in:
tianyongbao
2026-02-03 20:53:43 +08:00
parent c90ba0c31b
commit 6ab90d6fe2

View File

@@ -76,3 +76,42 @@ export function deptTreeSelect() {
method: 'get'
})
}
// 用户头像上传
export function uploadAvatar(data) {
return request({
url: '/system/user/profile/avatar',
method: 'post',
data: data
})
}
// 查询用户个人信息
export function getUserProfile() {
return request({
url: '/system/user/profile',
method: 'get'
})
}
// 修改用户个人信息
export function updateUserProfile(data) {
return request({
url: '/system/user/profile',
method: 'put',
data: data
})
}
// 修改用户密码
export function updateUserPwd(oldPassword, newPassword) {
const data = {
oldPassword,
newPassword
}
return request({
url: '/system/user/profile/updatePwd',
method: 'put',
data: data
})
}