feat(miniprogram): 通知 Tab 对接 erp-message 消息 API — 替换空壳
This commit is contained in:
12
apps/miniprogram/src/services/notification.ts
Normal file
12
apps/miniprogram/src/services/notification.ts
Normal file
@@ -0,0 +1,12 @@
|
||||
import { api } from './request';
|
||||
|
||||
export const notificationService = {
|
||||
list: (params?: { page?: number; page_size?: number }) =>
|
||||
api.get('/messages', params as Record<string, string | number | undefined>),
|
||||
markRead: (id: string) =>
|
||||
api.put(`/messages/${id}/read`),
|
||||
markAllRead: () =>
|
||||
api.put('/messages/read-all'),
|
||||
getUnreadCount: () =>
|
||||
api.get('/messages/unread-count'),
|
||||
};
|
||||
Reference in New Issue
Block a user