mirror of https://github.com/halo-dev/halo
Complete user api
parent
8cdba1b824
commit
ce70dcd199
|
@ -0,0 +1,22 @@
|
|||
import service from '@/utils/service'
|
||||
|
||||
const baseUrl = '/admin/api/users'
|
||||
|
||||
const userApi = {}
|
||||
|
||||
userApi.getProfile = () => {
|
||||
return service({
|
||||
url: `${baseUrl}/profile`,
|
||||
method: 'get'
|
||||
})
|
||||
}
|
||||
|
||||
userApi.updateProfile = updatedUserProfile => {
|
||||
return service({
|
||||
url: `${baseUrl}/profile`,
|
||||
method: 'put',
|
||||
data: updatedUserProfile
|
||||
})
|
||||
}
|
||||
|
||||
export default userApi
|
Loading…
Reference in New Issue