import request from '@/utils/request'

export function listAssembly(query) {
  return request({
    url: '/warehouse-assembly/page',
    method: 'get',
    params: query
  })
}

export function executeAssembly(query) {
  return request({
    url: '/warehouse-assembly/execute',
    method: 'post',
    params: query
  })
}

export function createAssembly(data) {
  return request({
    url: '/warehouse-assembly/add',
    method: 'post',
    data
  })
}

export function readAssembly(query) {
  return request({
    url: '/warehouse-assembly/info',
    method: 'get',
    params: query
  })
}

export function updateAssembly(data) {
  return request({
    url: '/warehouse-assembly/edit',
    method: 'post',
    data
  })
}

export function deleteAssembly(query) {
  return request({
    url: '/warehouse-assembly/remove',
    method: 'post',
    params: query
  })
}

export function cancelAssembly(query) {
  return request({
    url: '/warehouse-assembly/cancel',
    method: 'post',
    params: query
  })
}
