import { TTaskDown,TTaskDownQueryParam } from '@/types'
import request from '@/until/request'

/**
 * 获取远程配置任务列表
 * @param data TTaskDownQueryParam
 */
 const QueryTTaskDownList = (data: TTaskDownQueryParam) =>
 request({
     url: '/TTaskDownAction/list',
     method: 'post',
     data: data
 })

/**
* 新增远程配置任务
* @param data TTaskDown
*/
const AddTTaskDown = (data: TTaskDown) =>
 request({
     url: '/TTaskDownAction/saveTTaskDown',
     method: 'post',
     data: data
 })

/**
* 编辑远程配置任务
* @param data TTaskDown
*/
const EditTTaskDown = (data: TTaskDown) =>
 request({
     url: '/TTaskDownAction/updateTTaskDown',
     method: 'post',
     data: data
 })

/**
* 删除远程配置任务
* @param  id number
*/
const DeleteTTaskDown = (id: number) =>
 request({
     url: '/TTaskDownAction/deleteTTaskDown/' + id,
     method: 'get',
 })

export default {
 QueryTTaskDownList,
 AddTTaskDown,
 EditTTaskDown,
 DeleteTTaskDown
}