import axios from 'axios';
import config from '@api/config.js';
const urls = config.urls;
function request(config) {
  const instance = axios.create({
    baseURL: "http://192.168.2.121:7010",
    timeout: 500000,
    headers: {
      'Content-Type': "application/json;charset=utf-8"
    }
  })
  return instance(config)
}

export default {
  getTremList(param) {
    return axios.post(urls.getConceptKnowledgeCDSS, param);
  },
  getAllConcept(param) {
    //医学术语--获取所有概念（标准术语）
    return axios.post(urls.getAllConceptCDSS, param);
  },
  saveTermPrompts(param) {
    return axios.post(urls.saveConceptInfoCDSS, param);
  },

  delLisMappingById(param) {
    //医学数据-化验大小项与公表项维护-单个删除
    return axios.post(urls.delLisMappingByIdCDSS, param);
  },
  getConceptInfoAssay(param) {
    return axios.post(urls.getConceptInfoAssayCDSS, param); //化验子项-搜索术语
  },
  getAllLisConcept(param) {
    //医学数据-化验大小项与公表项维护-获取所有化验公表项
    return axios.post(urls.getAllLisConceptCDSS, param);
  },
  saveLisMapping(param) {
    //医学数据-化验大小项与公表项维护-新增
    return axios.post(urls.saveLisMappingCDSS, param);
  },
  hasLisMapping(param) {
    //医学数据-化验大小项与公表项维护-化验公表项映射是否已存在
    return axios.post(urls.hasLisMappingCDSS, param);
  },
  delConceptInfo(param) {
    return axios.post(urls.delConceptInfoCDSS, param);
  },
  getConceptKnowledgeList(param) {
    return axios.post(urls.getConceptKnowledgeListCDSS, param);
  },




  retrievalSearch(param) {
    // 术语搜索
    return axios.post(urls.retrievalSearchCDSS, param);
  },
  getLisMappingPage(param) {
    //诊断列表-列表
    return axios.post(urls.getLisMappingPageCDSS, param);
  },
  diseaseIsExistRecord(param) {
    return axios.post(urls.diseaseIsExistRecordCDSS, param);
  },
  saveOrUpdateDiseaseRecord(param) {
    return axios.post(urls.saveOrUpdateDiseaseRecordCDSS, param);
  },
  deleteDiseaseRecord(param) {
    return axios.post(urls.deleteDiseaseRecordCDSS, param);
  },
  exportDiseaseRecord(param) {
    return axios.post(urls.exportDiseaseRecordCDSS, param, {
      responseType: 'blob',
    });
  },
  importDiseaseRecord(param) {
    return axios.post(urls.importDiseaseRecordCDSS, param);
  },



  getLisPage(param) {
    //检验列表-列表
    return axios.post(urls.getLisPageCDSS, param);
  },
  lisIsExistRecord(param) {
    return axios.post(urls.lisIsExistRecordCDSS, param);
  },
  saveOrUpdateLisRecord(param) {
    return axios.post(urls.saveOrUpdateLisRecordCDSS, param);
  },
  deleteLisRecord(param) {
    return axios.post(urls.deleteLisRecordCDSS, param);
  },
  exportLisRecord(param) {
    return axios.post(urls.exportLisRecordCDSS, param, {
      responseType: 'blob',
    });
  },
  importLisRecord(param) {
    return axios.post(urls.importLisRecordCDSS, param);
  },
  getpacsPage(param) {
    //检查列表-列表
    return axios.post(urls.getpacsPageCDSS, param);
  },
  pacsIsExistRecord(param) {
    return axios.post(urls.pacsIsExistRecordCDSS, param);
  },
  saveOrUpdatePacsRecord(param) {
    return axios.post(urls.saveOrUpdatePacsRecordCDSS, param);
  },
  deletePacsRecord(param) {
    return axios.post(urls.deletePacsRecordCDSS, param);
  },
  exportPacsRecord(param) {
    return axios.post(urls.exportPacsRecordCDSS, param, {
      responseType: 'blob',
    });
  },
  importPacsRecord(param) {
    return axios.post(urls.importPacsRecordCDSS, param);
  },
  getDrugPage(param) {
    //药品列表-列表
    return axios.post(urls.getDrugPageCDSS, param);
  },
  drugIsExistRecord(param) {
    return axios.post(urls.drugIsExistRecordCDSS, param);
  },
  saveOrUpdateDrugRecord(param) {
    return axios.post(urls.saveOrUpdateDrugRecordCDSS, param);
  },
  deleteDrugRecord(param) {
    return axios.post(urls.deleteDrugRecordCDSS, param);
  },
  exportDrugRecord(param) {
    return axios.post(urls.exportDrugRecordCDSS, param, {
      responseType: 'blob',
    });
  },
  importDrugRecord(param) {
    return axios.post(urls.importDrugRecordCDSS, param);
  },
  getOperationPage(param) {
    //手术/操作列表-列表
    return axios.post(urls.getOperationPageCDSS, param);
  },
  operationIsExistRecord(param) {
    return axios.post(urls.operationIsExistRecordCDSS, param);
  },
  saveOrUpdateOperationRecord(param) {
    return axios.post(urls.saveOrUpdateOperationRecordCDSS, param);
  },
  deleteOperationRecord(param) {
    return axios.post(urls.deleteOperationRecordCDSS, param);
  },
  exportOperationRecord(param) {
    return axios.post(urls.exportOperationRecordCDSS, param, {
      responseType: 'blob',
    });
  },
  importOperationRecord(param) {
    return axios.post(urls.importOperationRecordCDSS, param);
  },
  getFusionPage(param) {
    //输血列表-列表
    return axios.post(urls.getFusionPageCDSS, param);
  },
  fusionIsExistRecord(param) {
    return axios.post(urls.fusionIsExistRecordCDSS, param);
  },
  saveOrUpdateFusionRecord(param) {
    return axios.post(urls.saveOrUpdateFusionRecordCDSS, param);
  },
  deleteFusionRecord(param) {
    return axios.post(urls.deleteFusionRecordCDSS, param);
  },
  exportFusionRecord(param) {
    return axios.post(urls.exportFusionRecordCDSS, param, {
      responseType: 'blob',
    });
  },
  importFusionRecord(param) {
    return axios.post(urls.importFusionRecordCDSS, param);
  },
  getDeptPage(param) {
    //科室列表-列表
    return axios.post(urls.getDeptPageCDSS, param);
  },
  deptIsExistRecord(param) {
    return axios.post(urls.deptIsExistRecordCDSS, param);
  },
  saveOrUpdateDeptRecord(param) {
    return axios.post(urls.saveOrUpdateDeptRecordCDSS, param);
  },
  deleteDeptRecord(param) {
    return axios.post(urls.deleteDeptRecordCDSS, param);
  },
  exportDeptRecord(param) {
    return axios.post(urls.exportDeptRecordCDSS, param, {
      responseType: 'blob',
    });
  },
  importDeptRecord(param) {
    return axios.post(urls.importDeptRecordCDSS, param);
  },
  exportDeptModule(param) {
    return axios.post(urls.exportDeptModuleCDSS, param, {
      responseType: 'blob',
    });
  },

  exportDiseaseModule(param) {
    return axios.post(urls.exportDiseaseModuleCDSS, param, {
      responseType: 'blob',
    });
  },
  exportLisModule(param) {
    return axios.post(urls.exportLisModuleCDSS, param, {
      responseType: 'blob',
    });
  },
  exportPacsModule(param) {
    return axios.post(urls.exportPacsModuleCDSS, param, {
      responseType: 'blob',
    });
  },
  exportDrugModule(param) {
    return axios.post(urls.exportDrugModuleCDSS, param, {
      responseType: 'blob',
    });
  },
  exportOperationModule(param) {
    return axios.post(urls.exportOperationModuleCDSS, param, {
      responseType: 'blob',
    });
  },
  exportFusionModule(param) {
    return axios.post(urls.exportFusionModuleCDSS, param, {
      responseType: 'blob',
    });
  },



  getHospitalInfo(param) {
    return axios.post(urls.getHospitalInfoCDSS, param);
  },
  saveHospitalInfoRecord(param) {
    return axios.post(urls.saveHospitalInfoRecordCDSS, param);
  },


  getPlanInfoPages(param) {
    //分页获取方案配置信息
    return axios.post(urls.getPlanInfoPagesCDSS, param);
  },
  getDefaultPlans(param) {
    return axios.post(urls.getDefaultPlansCDSS, param);
  },
  savePlanInfoDatas(param) {
    return axios.post(urls.savePlanInfoDatasCDSS, param);
  },
  cancelPlanDatas(param) {
    return axios.post(urls.cancelPlanDatasCDSS, param);
  },
  getPlanInfoIds(param) {
    return axios.post(urls.getPlanInfoIdsCDSS, param);
  },
  revStopPlans(param) {
    return axios.post(urls.revStopPlansCDSS, param);
  },



  getMappingListPageCDSS(param) {
    return axios.post(urls.getMappingListPageCDSS, param);
  },
  modifyConnectStatusCDSS(param) {
    return axios.post(urls.modifyConnectStatusCDSS, param);
  },
  getHospitalPageCDSS(param) {
    return axios.post(urls.getHospitalPageCDSS, param);
  },
  saveOrUpdateHosRecordCDSS(param) {
    return axios.post(urls.saveOrUpdateHosRecordCDSS, param);
  },
  deleteHosRecordCDSS(param) {
    return axios.post(urls.deleteHosRecordCDSS, param);
  },
  getUserRoleCDSS(param) {
    return axios.post(urls.getUserRoleCDSS, param);
  },
  cancelUserRoleCDSS(param) {
    return axios.post(urls.cancelUserRoleCDSS, param);
  },
  addUserRoleCDSS(param) {
    return axios.post(urls.addUserRoleCDSS, param);
  },
  getVersionInfoAllsCDSS(param) {
    return axios.post(urls.getVersionInfoAllsCDSS, param);
  },
  saveVersionInfoAllsCDSS(param) {
    return axios.post(urls.saveVersionInfoAllsCDSS, param);
  },
  cancelVersionInfoAllsCDSS(param) {
    return axios.post(urls.cancelVersionInfoAllsCDSS, param);
  },
  updateVersionInfoAllsCDSS(param) {
    return axios.post(urls.updateVersionInfoAllsCDSS, param);
  },
  addVersionDetailsCDSS(param) {
    return axios.post(urls.addVersionDetailsCDSS, param);
  },
  cancelVersionDetailsCDSS(param) {
    return axios.post(urls.cancelVersionDetailsCDSS, param);
  },
  getDetailByIdCDSS(param) {
    return axios.post(urls.getDetailByIdCDSS, param);
  },
  updateVersionDetailsCDSS(param) {
    return axios.post(urls.updateVersionDetailsCDSS, param);
  },

  addDisclaimerInfosCDSS(param) {
    return axios.post(urls.addDisclaimerInfosCDSS, param);
  },
  cancelDisclaimerInformationsCDSS(param) {
    return axios.post(urls.cancelDisclaimerInformationsCDSS, param);
  },
  endDisclaimerInformationsCDSS(param) {
    return axios.post(urls.endDisclaimerInformationsCDSS, param);
  },
  getDisclaimerPagesCDSS(param) {
    return axios.post(urls.getDisclaimerPagesCDSS, param);
  },
  startDisclaimerInformationsCDSS(param) {
    return axios.post(urls.startDisclaimerInformationsCDSS, param);
  },
  updateDisclaimerInformationsCDSS(param) {
    return axios.post(urls.updateDisclaimerInformationsCDSS, param);
  },
  getKlmEnumsDataCDSS(param) {
    return axios.post(urls.getKlmEnumsDataCDSS, param);
  },
  changeStatusCDSS(param) {
    return axios.post(urls.changeStatusCDSS, param);
  },
  getListDicCDSS(param) {
    return axios.post(urls.getListDicCDSS, param);
  },



  precDeptDataMatch(param) {
    return axios.post(urls.precDeptDataMatch, param, {
      responseType: 'blob',
    });
  },
  precDrugDataMatch(param) {
    return axios.post(urls.precDrugDataMatch, param, {
      responseType: 'blob',
    });
  },
  precDiseaseDataMatch(param) {
    return axios.post(urls.precDiseaseDataMatch, param, {
      responseType: 'blob',
    });
  },
  precLisDataMatch(param) {
    return axios.post(urls.precLisDataMatch, param, {
      responseType: 'blob',
    });
  },
  precPacsDataMatch(param) {
    return axios.post(urls.precPacsDataMatch, param, {
      responseType: 'blob',
    });
  },
  precOperationDataMatch(param) {
    return axios.post(urls.precOperationDataMatch, param, {
      responseType: 'blob',
    });
  },
  precFusionDataMatch(param) {
    return axios.post(urls.precFusionDataMatch, param, {
      responseType: 'blob',
    });
  },
  dataDeptVerify(param) {
    return axios.post(urls.dataDeptVerify, param);
  },
  dataFusionVerify(param) {
    return axios.post(urls.dataFusionVerify, param);
  },
  dataOperationVerify(param) {
    return axios.post(urls.dataOperationVerify, param);
  },
  dataDrugVerify(param) {
    return axios.post(urls.dataDrugVerify, param);
  },
  dataPacsVerify(param) {
    return axios.post(urls.dataPacsVerify, param);
  },
  dataLisVerify(param) {
    return axios.post(urls.dataLisVerify, param);
  },
  dataDiseaseVerify(param) {
    return axios.post(urls.dataDiseaseVerify, param);
  },

  getEntityPageCDSS(param) {
    return request({ method: 'post', url: urls.getEntityPageCDSS, data: param });
  },
  isEntitymanExistCDSS(param) {
    return request({ method: 'post', url: urls.isEntitymanExistCDSS, data: param });
  },
  saveEntity(param) {
    return request({ method: 'post', url: urls.saveEntity, data: param });
  },
  getEntitymanById(param) {
    return request({ method: 'post', url: urls.getEntitymanById, data: param });
  },
  dataEntityVerify(param) {
    return request({ method: 'post', url: urls.dataEntityVerify, data: param });
  },
  BatchUpdateHasInfoStatus(param) {
    return request({ method: 'post', url: urls.BatchUpdateHasInfoStatus, data: param });
  },

  getCaseResultList(param) {
    return axios.post(urls.getCaseResultList, param);
  },
  billRuleTest(param) {
    return axios.post(urls.billRuleTest, param, { timeout: 30 * 60 * 1000 });
  },
  getResultBillPage(param) {
    return axios.post(urls.getResultBillPage, param);
  },
  ruleAllTest(param) {
    return axios.post(urls.ruleAllTest, param);
  },
  exportRuleExcel(param) {
    return axios.post(urls.exportRuleExcel, param, {
      responseType: 'blob',
    });
  },
  criticalRuleTest(param) {
    return axios.post(urls.criticalRuleTest, param, { timeout: 30 * 60 * 1000 });
  },
  getResultCriticalPage(param) {
    return axios.post(urls.getResultCriticalPage, param);
  },
  highRiskRuleTest(param) {
    return axios.post(urls.highRiskRuleTest, param, { timeout: 30 * 60 * 1000 });
  },
  getResultHighriskDrugPage(param) {
    return axios.post(urls.getResultHighriskDrugPage, param);
  },
  otherRuleTest(param) {
    return axios.post(urls.otherRuleTest, param, { timeout: 30 * 60 * 1000 });
  },
  getResultHighriskOperationPage(param) {
    return axios.post(urls.getResultHighriskOperationPage, param);
  },
  getResultOtherLisPage(param) {
    return axios.post(urls.getResultOtherLisPage, param);
  },
  getResultOtherPacsPage(param) {
    return axios.post(urls.getResultOtherPacsPage, param);
  },
  getResultOtherTransfusionPage(param) {
    return axios.post(urls.getResultOtherTransfusionPage, param);
  },
  billExportExcel(param) {
    return axios.post(urls.billExportExcel, param, {
      responseType: 'blob',
    });
  },
  criticalExportExcel(param) {
    return axios.post(urls.criticalExportExcel, param, {
      responseType: 'blob',
    });
  },
  highriskDrugExportExcel(param) {
    return axios.post(urls.highriskDrugExportExcel, param, {
      responseType: 'blob',
    });
  },
  highriskOperationExportExcel(param) {
    return axios.post(urls.highriskOperationExportExcel, param, {
      responseType: 'blob',
    });
  },
  otherLisExportExcel(param) {
    return axios.post(urls.otherLisExportExcel, param, {
      responseType: 'blob',
    });
  },
  otherPacsExportExcel(param) {
    return axios.post(urls.otherPacsExportExcel, param, {
      responseType: 'blob',
    });
  },
  otherTransfusionExportExcel(param) {
    return axios.post(urls.otherTransfusionExportExcel, param, {
      responseType: 'blob',
    });
  },
  exportStaticCommonExcel(param) {
    return axios.post(urls.exportStaticCommonExcel, param, {
      responseType: 'blob',
    });
  },
  exportStaticCommonStaticExcel(param) {
    return axios.post(urls.exportStaticCommonStaticExcel, param, {
      responseType: 'blob',
    });
  },
  exportStaticLisExcel(param) {
    return axios.post(urls.exportStaticLisExcel, param, {
      responseType: 'blob',
    });
  },
  exportStaticLisStaticExcel(param) {
    return axios.post(urls.exportStaticLisStaticExcel, param, {
      responseType: 'blob',
    });
  },

  getStaticCaseResultList(param) {
    return axios.post(urls.getStaticCaseResultList, param);
  },
  getStaticPage(param) {
    return axios.post(urls.getStaticPage, param);
  },
  staticKnowledgeTest(param) {
    return axios.post(urls.staticKnowledgeTest, param, { timeout: 30 * 60 * 1000 });
  },
  getRunningStatus(param) {
    return axios.post(urls.getRunningStatus, param);
  },
  getRunningStatusByHospitalId(param) {
    return axios.post(urls.getRunningStatusByHospitalId, param);
  },
  updateRunningStatus(param) {
    return axios.post(urls.updateRunningStatus, param);
  },
};
