import request from '@/utils/request'

// 查询计划企业列表
export function listEnterprise(query) {
  return request({
    url: '/pharmaceuticals/bPlanEnterprise/list',
    method: 'get',
    params: query
  })
}

// 查询计划企业详细
export function getEnterprise(id) {
  return request({
    url: '/system/enterprise/' + id,
    method: 'get'
  })
}

// 新增计划企业
export function addEnterprise(data) {
  return request({
    url: '/pharmaceuticals/bPlanEnterprise',
    method: 'post',
    data: data
  })
}

// 修改计划企业
export function updateEnterprise(data) {
  return request({
    url: '/pharmaceuticals/bPlanEnterprise',
    method: 'put',
    data: data
  })
}

// 删除计划企业
export function delEnterprise(id) {
  return request({
    url: '/pharmaceuticals/bPlanEnterprise?idList=' + id,
    method: 'delete'
  })
}
