mirror of
https://github.com/continew-org/continew-admin-ui.git
synced 2026-01-15 02:57:09 +08:00
refactor: 适配后端删除接口重构,由 URL 传参重构为请求体传参
This commit is contained in:
@@ -11,13 +11,18 @@ export function listMessage(query: T.MessagePageQuery) {
|
||||
}
|
||||
|
||||
/** @desc 删除消息 */
|
||||
export function deleteMessage(ids: string | Array<string>) {
|
||||
return http.del(`${BASE_URL}/${ids}`)
|
||||
export function deleteMessage(ids: Array<string>) {
|
||||
return http.del(`${BASE_URL}`, { ids })
|
||||
}
|
||||
|
||||
/** @desc 标记已读 */
|
||||
export function readMessage(ids?: string | Array<string>) {
|
||||
return http.patch(`${BASE_URL}/read`, ids)
|
||||
export function readMessage(ids?: Array<string>) {
|
||||
return http.patch(`${BASE_URL}/read`, { ids })
|
||||
}
|
||||
|
||||
/** @desc 全部已读 */
|
||||
export function readAllMessage() {
|
||||
return http.patch(`${BASE_URL}/readAll`)
|
||||
}
|
||||
|
||||
/** @desc 查询未读消息数量 */
|
||||
|
||||
Reference in New Issue
Block a user