import request from '@/utils/request'

/**
 * 获取个人组套
 * @param {*} queryParams
 */
export function getPersonalList(queryParams) {
    return request({
      url: '/personalization/orders-group-package/get-personal',
      method: 'get',
      params: queryParams
    })
}

/**
 * 获取科室组套
 * @param {*} queryParams
 */
export function getDeptList(queryParams) {
    return request({
      url: '/personalization/orders-group-package/get-organization',
      method: 'get',
      params: queryParams
    })
}

/**
 * 获取全院组套
 * @param {*} queryParams
 */
export function getAllList(queryParams) {
    return request({
      url: '/personalization/orders-group-package/get-hospital',
      method: 'get',
      params: queryParams
    })
}

/**
 * 保存个人组套
 * @param {*} data
 */
export function savePersonal(data) {
  return request({
    url: '/personalization/orders-group-package/save-personal',
    method: 'post',
    data: data
  })
}

/**
 * 保存科室组套
 * @param {*} data
 */
export function saveDepartment(data) {
  return request({
    url: '/personalization/orders-group-package/save-organization',
    method: 'post',
    data: data
  })
}

/**
 * 保存全院组套
 * @param {*} data
 */
export function saveAll(data) {
  return request({
    url: '/personalization/orders-group-package/save-hospital',
    method: 'post',
    data: data
  })
}

/**
 * 查询组套明细
 * @param {*} data
 */
export function queryGroupDetail(params) {
  return request({
    url: '/personalization/orders-group-package/get-group-package-detail',
    method: 'get',
    params: params
  })
}

/**
 * 删除组套
 * @param {*} data
 */
export function deleteGroup(data) {
  return request({
    url: '/personalization/orders-group-package/group-package-detail?groupPackageId=' + data.groupPackageId,
    method: 'delete'
  })
}

/**
 * 查询参与者下拉列表
 * @param {*} data
 */
export function queryParticipantList(params) {
  return request({
    url: '/app-common/practitioner-list',
    method: 'get',
    params: params
  })
}

/**
 * 获取药品列表
 */
export function getAdviceBaseInfo(queryParams) {
  return request({
    url: '/doctor-station/advice/advice-base-info',
    method: 'get',
    params: queryParams
  })
}

/**
 * 获取科室列表
 */
export function getOrgTree() {
  return request({
    url: '/base-data-manage/organization/organization',
    method: 'get',
  })
}
