| | |
| | | // 查询消息通知列表 |
| | | export function listMessage(query) { |
| | | return request({ |
| | | url: "/system/message/list", |
| | | url: "/system/notice/list", |
| | | method: "get", |
| | | params: query, |
| | | }); |
| | |
| | | // 查询未读消息数量 |
| | | export function getUnreadCount() { |
| | | return request({ |
| | | url: "/system/message/unreadCount", |
| | | url: "/system/notice/getCount", |
| | | method: "get", |
| | | }); |
| | | } |
| | | |
| | | // 标记消息为已读 |
| | | export function markAsRead(messageId) { |
| | | export function markAsRead(noticeId) { |
| | | return request({ |
| | | url: "/system/message/markAsRead", |
| | | url: "/system/notice/markAsRead", |
| | | method: "post", |
| | | data: { messageId }, |
| | | data: { noticeId }, |
| | | }); |
| | | } |
| | | |
| | | // 一键标记所有消息为已读 |
| | | export function markAllAsRead() { |
| | | return request({ |
| | | url: "/system/message/markAllAsRead", |
| | | url: "/system/notice/markAllAsRead", |
| | | method: "post", |
| | | }); |
| | | } |
| | | |
| | | // 确认消息 |
| | | export function confirmMessage(messageId) { |
| | | export function confirmMessage(noticeId, status) { |
| | | return request({ |
| | | url: "/system/message/confirm", |
| | | url: "/system/notice/confirm", |
| | | method: "post", |
| | | data: { messageId }, |
| | | data: { noticeId, status }, |
| | | }); |
| | | } |