import request from '@/utils/request'

// 查询验证任务详情列表
export function listDetail(query) {
  return request({
    url: '/biz/detail/list',
    method: 'get',
    params: query
  })
}

// 查询验证任务详情详细
export function getDetail(id) {
  return request({
    url: '/biz/detail/' + id,
    method: 'get'
  })
}

// 新增验证任务详情
export function addDetail(data) {
  return request({
    url: '/biz/detail',
    method: 'post',
    data: data
  })
}

// 修改验证任务详情
export function updateDetail(data) {
  return request({
    url: '/biz/detail',
    method: 'put',
    data: data
  })
}

// 删除验证任务详情
export function delDetail(id) {
  return request({
    url: '/biz/detail/' + id,
    method: 'delete'
  })
}

export function verification(taskid) {
  return request({
    url: '/biz/detail/verification',
    method: 'get',
    params: { taskid: taskid }
  })
}
export function getTraindataset(query){
  return request({
    url:'/biz/train/list',
    method:'get',
    params: query
  })
}

// 更新验证任务详情
export function updateDetails(dataset) {
  return request({
    url: '/biz/detail/updateDetails',
    method: 'post',
    data: dataset,

  })
}

//得到运行验证任务详情
export function getUpdatedDetails(taskids,pageNum,pageSize){
  return request({
    url:`/biz/detail/getUpdatedDetails?pageNum=${pageNum}&pageSize=${pageSize}`,
    method:'post',
    data: taskids,
  })
}
