import request from '@/utils/request'

// 分页查询车辆货物运输列表
export function pageListTrans(query) {
  return request({
    url: '/order/trans/pageList',
    method: 'get',
    params: query
  })
}

// 查询车辆货物运输列表
export function listTrans(query) {
  return request({
    url: '/order/trans/list',
    method: 'get',
    params: query
  })
}

// 查询车辆货物运输详细
export function getTrans(ID) {
  return request({
    url: '/order/trans/' + ID,
    method: 'get'
  })
}

// 新增车辆货物运输
export function addTrans(data) {
  return request({
    url: '/order/trans',
    method: 'post',
    data: data
  })
}

// 修改车辆货物运输
export function updateTrans(data) {
  return request({
    url: '/order/trans',
    method: 'put',
    data: data
  })
}

// 批量修改新增运输计划
export function saveTrans(data) {
  return request({
    url: '/order/trans/saveTrans',
    method: 'post',
    data: data
  })
}

// 删除车辆货物运输
export function delTrans(ID) {
  return request({
    url: '/order/trans/' + ID,
    method: 'delete'
  })
}

// 导出车辆货物运输
export function exportTrans(query) {
  return request({
    url: '/order/trans/' + 'export',
    method: 'post',
    params: query
  })
}
