调试接口
This commit is contained in:
@ -1,7 +1,5 @@
|
||||
import { http } from '@/http/alova'
|
||||
import type { IUserAddressListResult, IUserAddressDetailsResult, IUserCouponListResult } from '@/api/types/user'
|
||||
import type { IOrderListResult } from '@/api/types/teaSpecialist-order'
|
||||
import type { IUserResult } from '@/api/types/user'
|
||||
|
||||
/**
|
||||
* 修改用户信息
|
||||
@ -19,6 +17,20 @@ export function updateUserInfo(data: IUpdateUserInfoParams) {
|
||||
return http.Post('/storeapi/user/updateUser', data)
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改头像
|
||||
*/
|
||||
export function updateUserAvatar(avatar: string) {
|
||||
return http.Post('/teamapi/user/editAvatar', { avatar })
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改昵称
|
||||
*/
|
||||
export function updateUserNickname(nickname: string) {
|
||||
return http.Post('/teamapi/user/editNickname', { nickname })
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 获取用户信息
|
||||
@ -111,10 +123,11 @@ export interface IUserAddressListParams {
|
||||
longitude: number
|
||||
latitude: number
|
||||
address: string
|
||||
status: number
|
||||
}
|
||||
|
||||
export function getUserAddressList() {
|
||||
return http.Post<Array<IUserAddressListResult>>('/teamapi/user/addressList')
|
||||
return http.Post<Array<IUserAddressListParams>>('/teamapi/user/addressList')
|
||||
}
|
||||
|
||||
/**
|
||||
@ -150,3 +163,17 @@ export function editUserAddress(data: IAddUserAddressListParams & { id: number }
|
||||
export function deleteUserAddress(id: number) {
|
||||
return http.Post('/teamapi/user/delAddress', { id })
|
||||
}
|
||||
|
||||
/**
|
||||
* 位置更新
|
||||
*/
|
||||
export function updateUserAddressLocation(id: number) {
|
||||
return http.Post('/teamapi/user/selAddress', { id })
|
||||
}
|
||||
|
||||
/**
|
||||
* 地址详情
|
||||
*/
|
||||
export function getUserAddressInfo(id: number) {
|
||||
return http.Post<any>('/teamapi/user/addressDetails', { id })
|
||||
}
|
||||
Reference in New Issue
Block a user