import { axios } from '@/utils/request'
// 连锁收发存报表-分页列表
export const linkageReportPageList = (params) => {
  const url = `report/reportStockPutOut/linkageReportPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 连锁收发存报表-列表合计
export const linkageReportPageTotal = (params) => {
  return axios({
    url: 'report/reportStockPutOut/linkageReportCount',
    data: params,
    method: 'post'
  })
}
// 连锁收发存报表  导出
export const reportChainStockPutOutExport = params => {
  return axios.request({
    url: `/report/reportStockPutOut/exportLinkageReport`,
    data: params,
    method: 'post',
    responseType: 'blob'
  })
}
// 收发存报表-分页列表
export const reportPageList = (params) => {
  const url = `report/reportStockPutOut/reportPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 收发存报表-列表合计
export const linkageReportTotal = (params) => {
  return axios({
    url: 'report/reportStockPutOut/linkageReportCount',
    data: params,
    method: 'post'
  })
}
// 收发存报表-列表合计
export const reportStockPutOutCount = (params) => {
  return axios({
    url: 'report/reportStockPutOut/reportCount',
    data: params,
    method: 'post'
  })
}
// 收发存报表  导出
export const reportStockPutOutExport = params => {
  return axios.request({
    url: `/report/reportStockPutOut/exportReport`,
    data: params,
    method: 'post',
    responseType: 'blob'
  })
}
// 大客户报表-分页列表
export const reportBigCustomerList = (params) => {
  const url = `report/reportBigCustomer/reportPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 大客户报表-列表合计
export const reportBigCustomerCount = (params) => {
  return axios({
    url: 'report/reportBigCustomer/reportCount',
    data: params,
    method: 'post'
  })
}
// 连锁大客户报表-分页列表
export const reportBigCustomerLinkageList = (params) => {
  const url = `report/reportBigCustomer/linkageReportPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 连锁大客户报表-列表合计
export const reportBigCustomerLinkageCount = (params) => {
  return axios({
    url: 'report/reportBigCustomer/linkageReportCount',
    data: params,
    method: 'post'
  })
}
// 连锁销售报表-分页列表
export const reportChainSalesBillList = (params) => {
  const url = `/report/reportSalesBill/linkageReportPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 连锁销售报表-列表合计
export const reportChainSalesBillCount = (params) => {
  return axios({
    url: '/report/reportSalesBill/linkageReportCount',
    data: params,
    method: 'post'
  })
}
// 连锁销售明细报表-分页列表
export const reportChainSalesBillDetailList = (params) => {
  const url = `/report/reportSalesBill/linkageReportDetailPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 连锁销售明细报表-列表合计
export const reportChainSalesBillDetailCount = (params) => {
  return axios({
    url: '/report/reportSalesBill/linkageReportDetailCount',
    data: params,
    method: 'post'
  })
}
// 销售报表-分页列表
export const reportSalesBillList = (params) => {
  const url = `/report/reportSalesBill/reportPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 销售报表-列表合计
export const reportSalesBillCount = (params) => {
  return axios({
    url: '/report/reportSalesBill/reportCount',
    data: params,
    method: 'post'
  })
}
// 销售明细报表-分页列表
export const reportSalesBillDetailList = (params) => {
  const url = `/report/reportSalesBill/reportDetailPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 销售明细报表-列表合计
export const reportSalesBillDetailCount = (params) => {
  return axios({
    url: '/report/reportSalesBill/reportDetailCount',
    data: params,
    method: 'post'
  })
}
// 连锁店
export const linkageGroupList = (params) => {
  return axios({
    url: '/report/linkageGroup/findListByDealerSn',
    data: params,
    method: 'post'
  })
}
// 销售报表  导出
export const reportSalesBillExport = params => {
  return axios.request({
    url: `/report/reportSalesBill/export`,
    data: params,
    method: 'post',
    responseType: 'blob'
  })
}
// 销售明细报表  导出
export const reportSalesBillDetailExport = params => {
  return axios.request({
    url: `/report/reportSalesBill/detailExport`,
    data: params,
    method: 'post',
    responseType: 'blob'
  })
}
// 盘点报表  盘点单报表 列表 分页
export const reportCheckWarehouseList = (params) => {
  const url = `/report/reportCheckWarehouse/reportPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 盘点报表  盘点单报表 合计
export const reportCheckWarehouseCount = (params) => {
  return axios({
    url: '/report/reportCheckWarehouse/reportCount',
    data: params,
    method: 'post'
  })
}
// 盘点报表  盘点明细报表 列表 分页
export const reportCheckWarehouseDetailList = (params) => {
  const url = `/report/reportCheckWarehouse/reportDetailPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 盘点报表  盘点明细报表 合计
export const reportCheckWarehouseDetailCount = (params) => {
  return axios({
    url: '/report/reportCheckWarehouse/reportDetailCount',
    data: params,
    method: 'post'
  })
}
// 采购入库报表  采购入库单报表 列表 分页
export const reportReceivingBillList = (params) => {
  const url = `/report/reportReceivingBill/reportPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 采购入库报表  采购入库单报表 合计
export const reportReceivingBillCount = (params) => {
  return axios({
    url: '/report/reportReceivingBill/reportCount',
    data: params,
    method: 'post'
  })
}
// 采购入库报表  采购入库单报表  导出
export const reportReceivingBillExport = params => {
  return axios.request({
    url: `/report/reportReceivingBill/export`,
    data: params,
    method: 'post',
    responseType: 'blob'
  })
}
// 采购入库报表  采购入库明细报表 列表 分页
export const reportReceivingBillDetailList = (params) => {
  const url = `/report/reportReceivingBill/reportDetailPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 采购入库报表  采购入库明细报表 合计
export const reportReceivingBillDetailCount = (params) => {
  return axios({
    url: '/report/reportReceivingBill/reportDetailCount',
    data: params,
    method: 'post'
  })
}
// 采购入库报表  采购入库明细报表  导出
export const reportReceivingBillDetailExport = params => {
  return axios.request({
    url: `/report/reportReceivingBill/detailExport`,
    data: params,
    method: 'post',
    responseType: 'blob'
  })
}
// 连锁采购入库报表  连锁采购入库单报表 列表 分页
export const reportChainReceivingBillList = (params) => {
  const url = `/report/reportReceivingBill/linkageReportPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 连锁采购入库报表  连锁采购入库单报表 合计
export const reportChainReceivingBillCount = (params) => {
  return axios({
    url: '/report/reportReceivingBill/linkageReportCount',
    data: params,
    method: 'post'
  })
}
// 连锁采购入库报表  连锁采购入库明细报表 列表 分页
export const reportChainReceivingBillDetailList = (params) => {
  const url = `/report/reportReceivingBill/linkageReportDetailPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 连锁采购入库报表  连锁采购入库明细报表 合计
export const reportChainReceivingBillDetailCount = (params) => {
  return axios({
    url: '/report/reportReceivingBill/linkageReportDetailCount',
    data: params,
    method: 'post'
  })
}
// 客户销售明细报表  列表 分页
export const reportCustomerSalesBillDetailList = (params) => {
  const url = `/report/reportCustomerSalesBillDetail/reportPage/${params.pageNo}/${params.pageSize}`
  delete params.pageNo
  delete params.pageSize
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 客户销售明细报表 合计
export const reportCustomerSalesBillDetailCount = (params) => {
  return axios({
    url: '/report/reportCustomerSalesBillDetail/reportCount',
    data: params,
    method: 'post'
  })
}
// 客户销售明细报表  导出
export const reportCustomerSalesBillDetailExport = params => {
  return axios.request({
    url: `/report/reportCustomerSalesBillDetail/export`,
    data: params,
    method: 'post',
    responseType: 'blob'
  })
}
// 连锁销售明细合计报表  列表 不分页
export const reportSalesBillDetailTotalList = (params) => {
  const url = `/report/reportSalesBillDetailTotal/report`
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 连锁销售明细合计报表  导出
export const reportSalesBillDetailTotalExport = params => {
  return axios.request({
    url: `/report/reportSalesBillDetailTotal/export`,
    data: params,
    method: 'post',
    responseType: 'blob'
  })
}
// 门店收发存汇总报表  列表 不分页
export const reportStockPutOutMonthList = (params) => {
  const url = `/report/reportStockPutOutMonth/report`
  return axios({
    url: url,
    data: params,
    method: 'post'
  })
}
// 门店收发存汇总报表  导出
export const reportStockPutOutMonthExport = params => {
  return axios.request({
    url: `/report/reportStockPutOutMonth/export`,
    data: params,
    method: 'post',
    responseType: 'blob'
  })
}
