import { request } from "@/utils/request";

/**
 * 获取未读消息数量
 */
export const getUnreadMessageCount = () =>
  request({
    url: '/system/notify-message/get-unread-count',
    method: 'GET',
  });

/**
 * 系统消息列表
 * @param params
 */
export const getMessageList = (params) =>
  request({
    url: '/system/notify-message/my-page',
    method: 'GET',
    params
  });

/**
 * 将消息标为已读
 * @param id
 */
export const markReadMessage = (id) =>
  request({
    url: '/system/notify-message/update-read',
    method: 'PUT',
    params: { ids: id }
  })
