/*
 * @Author: zc
 * @description 预警管理 -- 预警设置
 */
import request from '@/utils/request';
/**
 * @description 获取预警设置基础数据
 * @param {object}  params
 */
export const getEarlySettingBaseData = (params?: object) => {
	return request({
		url: `/api/v1/Early/earlysetting-basedata`,
		method: 'get',
		params,
	});
}
/**
 * @description 获取预警设置列表
 * @param {object}  params
 */
export const getEarlySettingList = (params?: object) => {
	return request({
		url: `/api/v1/Early/earlysetting-pagelist`,
		method: 'get',
		params,
	});
}
/**
 * @description 新增预警设置
 * @param {object}  data
 */
export const addEarlySetting = (data: object) => {
	return request({
		url: `/api/v1/Early/add-ealysetting`,
		method: 'post',
		data,
	});
}
/**
 * @description 修改预警设置
 * @param {object}  data
 */
export const editEarlySetting = (data: object) => {
	return request({
		url: `/api/v1/Early/update-ealysetting`,
		method: 'post',
		data,
	});
}
/**
 * @description 删除预警设置
 * @param {string}  id
 */
export const deleteEarlySetting = (id: string) => {
	return request({
		url: `/api/v1/Early/del-ealysetting?id=${id}`,
		method: 'delete',
	});
}
/**
 * @description 获取预警设置详情
 * @param {string}  id
 */
export const getEarlySettingDetail = (id: string) => {
	return request({
		url: `/api/v1/Early/get-earlysetting/${id}`,
		method: 'get',
	});
}