import request from '@/utils/request'

// 调拨订单列表
export function getOrderList(data) {
  return request({
    url: `/pu/allot/list?pageSize=${data.pageSize}&pageNum=${data.pageNum}&isAsc=desc&orderByColumn=updateTime`,
    method: 'post',
    data: data
  })
}
// 调拨订单新增
export function addOrder(data) {
  return request({
    url: `/pu/allot/add`,
    method: 'post',
    data: data
  })
}
// 调拨订单编辑
export function editOrder(data) {
  return request({
    url: `/pu/allot/edit`,
    method: 'put',
    data: data
  })
}
// 调拨订单提交
export function submitOrder(data) {
  return request({
    url: `/pu/allot/submit`,
    method: 'post',
    data: data
  })
}
// 调拨订单详情
// 调拨订单详情
export function getOrderDetail(id) {
  return request({
    url: `/pu/allot/detail/${id}`,
    method: 'get',
  })
}
// 调拨订单删除
export function delOrder(ids) {
  return request({
    url: `/pu/allot/delete/${ids}`,
    method: 'delete',
  })
}
// 货权预留单详情
export function getResevedDetail(id) {
  return request({
    url: `/pu/ownership/detail/${id}`,
    method: 'get',
  })
}