// @ts-ignore
/* eslint-disable */
import { request } from '@umijs/max';

/** 告警列表 */
export async function postAlarmList(
  params: API.SearchAlarmListParams,
  options?: { [key: string]: any },
) {
  return request<API.Response & { data?: API.PageResult; msg?: string }>(
    `/api/warning_info/`,
    {
      method: 'GET',
      headers: {
        'Content-Type': 'application/json',
      },
      params: {
        ...params,
      },
      ...(options || {}),
    },
  );
}
/** 忽略事件 */
export async function postIgnoringvents(
  body: API.IgnoringventsParams,
  options?: { [key: string]: any },
) {
  return request<API.Response & { data?: API.PageResult; msg?: string }>(
    `/api/detect_result/`,
    {
      method: 'POST',
      headers: {
        'Content-Type': 'application/json',
      },
      data: body,
      ...(options || {}),
    },
  );
}