import request from '@/utils/request';
// 删除供应商
export function deleteSupplier(supplierId) {
  return request({
    url: '/admin/supplier/delete',
    method: 'get',
    params: { supplierId }
  });
}
// 编辑供应商（增加修改）
export function editSupplierId(data) {
  return request({
    url: '/admin/supplier/edit',
    method: 'post',
    data
  });
}
// 供应商列表(id 和 supplierName)
export function getList(data) {
  return request({
    url: '/admin/supplier/getList',
    method: 'post',
    data
  });
}
// 供应商列表分页
export function getPageList(data) {
  return request({
    url: '/admin/supplier/getPageList',
    method: 'post',
    data
  });
}
// -----------------购买方---------------------
// 删除购买方
export function deletePurchaser(receivingId) {
  return request({
    url: '/admin/receiving/delete',
    method: 'get',
    params: { receivingId }
  });
}
// 编辑购买方（增加修改）
export function editPurchaser(data) {
  return request({
    url: '/admin/receiving/edit',
    method: 'post',
    data
  });
}
// 购买方列表(id 和 receivingName)
export function getPurchaserList(data) {
  return request({
    url: '/admin/receiving/getList',
    method: 'post',
    data
  });
}
// 购买方列表分页
export function getPurchaserPage(data) {
  return request({
    url: '/admin/receiving/getPageList',
    method: 'post',
    data
  });
}
