import request from '@/utils/request'

// 查询用药报告列表
export function listDrugReport(query) {
  return request({
    url: '/his/drugReport/list',
    method: 'get',
    params: query
  })
}

// 查询用药报告详细
export function getDrugReport(reportId) {
  return request({
    url: '/his/drugReport/' + reportId,
    method: 'get'
  })
}

// 新增用药报告
export function addDrugReport(data) {
  return request({
    url: '/his/drugReport',
    method: 'post',
    data: data
  })
}

// 修改用药报告
export function updateDrugReport(data) {
  return request({
    url: '/his/drugReport',
    method: 'put',
    data: data
  })
}

// 删除用药报告
export function delDrugReport(reportId) {
  return request({
    url: '/his/drugReport/' + reportId,
    method: 'delete'
  })
}

// 导出用药报告
export function exportDrugReport(query) {
  return request({
    url: '/his/drugReport/export',
    method: 'get',
    params: query
  })
}