import request from '@/utils/request'

import { downFile } from '@/utils/request'
/**
* 入库管理/入库记录表分页查询
* @param {查询条件} data
*/
export function listInInstoreRecord(query) {
  return request({
    url: 'business/InInstoreRecord/list',
    method: 'get',
    params: query,
  })
}


/**
* 新增入库管理/入库记录表
* @param data
*/
export function addInInstoreRecord(data) {
  return request({
    url: 'business/InInstoreRecord',
    method: 'post',
    data: data,
  })
}
export function AddCheckedSapDeliverInstoreDtlResult(data) {
  return request({
    url: 'business/InInstoreRecord/AddCheckedSapDeliverInstoreDtlResult',
    method: 'post',
    data: data,
  })
}
/**
* 修改入库管理/入库记录表
* @param data
*/
export function updateInInstoreRecord(data) {
  return request({
    url: 'business/InInstoreRecord',
    method: 'PUT',
    data: data,
  })
}

/**
* 获取入库管理/入库记录表详情
* @param {Id}
*/
export function getInInstoreRecord(id) {
  return request({
    url: 'business/InInstoreRecord/' + id,
    method: 'get'
  })
}

/**
* 删除入库管理/入库记录表
* @param {主键} pid
*/
export function delInInstoreRecord(pid) {
  return request({
    url: 'business/InInstoreRecord/' + pid,
    method: 'delete'
  })
}

// 清空入库管理/入库记录表
export function clearInInstoreRecord() {
  return request({
    url: 'business/InInstoreRecord/clean',
    method: 'delete'
  })
}

// 导出入库管理/入库记录表
export async function exportInInstoreRecord(query) {
  await downFile('business/InInstoreRecord/export', { ...query })
}

