Dining_Hall/api/system/user.js

47 lines
1023 B
JavaScript

import upload from '@/utils/upload'
import request from '@/utils/request'
// 用户密码重置
export function updateUserPwd(data) {
return request({
url: '/smart-canteen/custInfo/change/password',
method: 'post',
data
})
}
// 查询用户头像
export function getUserHeaderPhoto(data) {
return request({
url: '/smart-canteen/api/v4/app/custInfo/query/profile/photo',
method: 'post',
data
})
}
// 保存头像地址
export function saveUserHeaderPhoto(data) {
return request({
url: '/smart-canteen/api/v4/app/custInfo/save/profile/photo',
method: 'post',
data
})
}
// 修改用户个人信息
export function updateUserProfile(data) {
return request({
url: '/smart-canteen/custCasual/updateDetailInfoCasualForApp',
method: 'post',
data: data
})
}
// 用户头像上传
export function uploadAvatar(data) {
return upload({
url: '/system/user/profile/avatar',
name: data.name,
filePath: data.filePath
})
}