import { useMessage } from "/@/hooks/web/useMessage";
import { defHttp } from '/@/utils/http/axios';

const { createConfirm } = useMessage();

enum Api {
  statistics = '/stm.common/action/statistics',
  statisticsByCaNo = '/stm.common/action/statisticsByCaNo',
  statisticsByComplianceNo = '/stm.common/action/statisticsByComplianceNo',
  list = '/stm.common/action/list',
  listDuty = '/stm.common/action/listDuty',
}

export const list = (params) =>
  defHttp.get({url: Api.list, params});

export const listDuty = (params) =>
  defHttp.get({url: Api.listDuty, params});

export const statistics = () =>
  defHttp.get({url: Api.statistics});

export const statisticsByCaNo = (params) =>
  defHttp.get({url: Api.statisticsByCaNo,params});

export const statisticsByComplianceNo = (params) =>
  defHttp.get({url: Api.statisticsByComplianceNo,params});