feat: 新增消息中心

This commit is contained in:
2024-05-19 22:58:47 +08:00
parent 00da9acdd0
commit fdd4b9a4df
6 changed files with 189 additions and 1 deletions

View File

@@ -0,0 +1,19 @@
import type * as System from './type'
import http from '@/utils/http'
const BASE_URL = '/system/message'
/** @desc 查询消息列表 */
export function listMessage(query: System.MessagePageQuery) {
return http.get<PageRes<System.MessageResp[]>>(`${BASE_URL}`, query)
}
/** @desc 删除消息 */
export function deleteMessage(ids: string | Array<string>) {
return http.del(`${BASE_URL}/${ids}`)
}
/** @desc 标记已读 */
export function readMessage(ids: string | Array<string>) {
return http.patch(`${BASE_URL}/read`, ids)
}