import request from '@/utils/request'

// 定时任务

// 获取定时任务列表
export const list = (data) => {
  return request({
    url: '/point-strategy/monitor/job/list',
    method: 'post',
    data
  })
}

// 新增
export const addJob = (data) => {
    return request({
      url: '/point-strategy/monitor/job',
      method: 'post',
      data
    })
  }

// 修改状态
export const changeStatus = (data) => {
  return request({
    url: '/point-strategy/monitor/job/changeStatus',
    method: 'post',
    data
  })
}

// 修改任务
export const editJob = (data) => {
  return request({
    url: '/point-strategy/monitor/job/edit',
    method: 'post',
    data
  })
}

// 获取定时任务详情
export const getInfo = (params) => {
  return request({
    url: '/point-strategy/monitor/job/getInfo',
    method: 'get',
    params
  })
}

// 删除
export const remove = (data) => {
  return request({
    url: '/point-strategy/monitor/job/remove',
    method: 'post',
    data:data
  })
}


// 定时任务执行一次
export const oneRun = (data) => {
  return request({
    url: '/point-strategy/monitor/job/run',
    method: 'post',
    data
  })
}




