import request from '@/utils/request';

/**
 * 获取通知管理列表
 * @param {object} params
 * @returns {array} data
 */
export const getNoticeList = (params) => {
  return request.request({
    url: '/notice/get',
    method: 'get',
    params,
  });
};

/**
 * 创建通知
 * @param {object} params
 * @returns {array} data
 */
export const createNotice = (data) => {
  return request.request({
    url: '/notice/create',
    method: 'post',
    data,
  });
};

/**
 * 配置通知
 * @param {object} params
 * @returns {array} data
 */
export const updateNotice = (data) => {
  return request.request({
    url: '/notice/update',
    method: 'post',
    data,
  });
};

/**
 * 配置通知
 * @param {object} params
 * @returns {array} data
 */
export const deleteNotice = (data) => {
  return request.request({
    url: '/notice/delete',
    method: 'post',
    data,
  });
};
