import { defHttp } from '/@/utils/http/axios';
enum Api {
  getWardInfo = '/biz/sys/wardInfo/query/list',
  wardInfoAdd = '/biz/sys/wardInfo/add',
  wardInfoEdit = '/biz/sys/wardInfo/edit',
  changeStatus = '/biz/sys/wardInfo/modify/status/',
  WardInfoById = '/biz/sys/wardInfo/detail',
  delWard = '/biz/sys/wardInfo/removeByIds',
}

export const getWardInfo = (params?: object) => {
  return defHttp.post({ url: Api.getWardInfo, params: params });
};

export const wardInfoAdd = (params?: object) => {
  return defHttp.post({ url: Api.wardInfoAdd, params: params });
};

export const wardInfoEdit = (params?: object) => {
  return defHttp.post({ url: Api.wardInfoEdit, params: params });
};

export const changeStatus = (id: string) => {
  return defHttp.post({ url: Api.changeStatus + id });
};

export const delWard = (params?: object) => {
  return defHttp.post({ url: Api.delWard, params: params });
};

export const wardInfoById = (id?: string | number, params?: object) => {
  return defHttp.get({ url: Api.WardInfoById + '/' + id, params: params });
};
