|
@@ -1,23 +1,20 @@
|
|
|
package com.diagbot.facade;
|
|
|
|
|
|
import com.alibaba.fastjson.JSONObject;
|
|
|
-import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
|
|
import com.diagbot.client.bean.AdverseReaction;
|
|
|
import com.diagbot.client.bean.Medicition;
|
|
|
import com.diagbot.client.bean.MedicitionClass;
|
|
|
-import com.diagbot.dto.ConceptDetailDTO;
|
|
|
+import com.diagbot.dto.ConceptIntroduceDTO;
|
|
|
import com.diagbot.dto.ConceptRes;
|
|
|
import com.diagbot.entity.Concept;
|
|
|
-import com.diagbot.entity.ConceptDetail;
|
|
|
import com.diagbot.entity.wrapper.ConceptWrapper;
|
|
|
import com.diagbot.enums.ConceptTypeEnum;
|
|
|
import com.diagbot.enums.DisTypeEnum;
|
|
|
-import com.diagbot.enums.PositionTypeEnum;
|
|
|
import com.diagbot.enums.LexiconRSTypeEnum;
|
|
|
import com.diagbot.enums.LexiconTypeEnum;
|
|
|
+import com.diagbot.enums.PositionTypeEnum;
|
|
|
import com.diagbot.exception.CommonErrorCode;
|
|
|
import com.diagbot.exception.CommonException;
|
|
|
-import com.diagbot.util.BeanUtil;
|
|
|
import com.diagbot.util.EntityUtil;
|
|
|
import com.diagbot.util.FastJsonUtils;
|
|
|
import com.diagbot.util.ListUtil;
|
|
@@ -72,22 +69,18 @@ public class TreatmentFacade {
|
|
|
conceptIntroduceVO.setLibType(LexiconTypeEnum.DIAGNOSIS.getKey());
|
|
|
conceptIntroduceVO.setPosition(PositionTypeEnum.T3.getKey());
|
|
|
conceptIntroduceVO.setType(ConceptTypeEnum.Disease.getKey());
|
|
|
- List<ConceptDetail> commonTreatmentDetailList = conceptDetailFacade.getConceptDetailList(conceptIntroduceVO);
|
|
|
- if (ListUtil.isNotEmpty(commonTreatmentDetailList)) {
|
|
|
- ConceptDetailDTO commonDetailDTO = new ConceptDetailDTO();
|
|
|
- BeanUtil.copyProperties(commonTreatmentDetailList.get(0), commonDetailDTO);
|
|
|
- retMap.put("commonTreatment", commonDetailDTO);
|
|
|
+ ConceptIntroduceDTO commonTreatmentDetail = conceptDetailFacade.getConceptDetail(conceptIntroduceVO);
|
|
|
+ if (commonTreatmentDetail != null && ListUtil.isNotEmpty(commonTreatmentDetail.getDetails())) {
|
|
|
+ retMap.put("commonTreatment", commonTreatmentDetail.getDetails().get(0));
|
|
|
} else {
|
|
|
retMap.put("commonTreatment", null);
|
|
|
}
|
|
|
|
|
|
//手术治疗
|
|
|
conceptIntroduceVO.setPosition(PositionTypeEnum.T4.getKey());
|
|
|
- List<ConceptDetail> surgeryTreatmentDetailList = conceptDetailFacade.getConceptDetailList(conceptIntroduceVO);
|
|
|
- if (ListUtil.isNotEmpty(surgeryTreatmentDetailList)) {
|
|
|
- ConceptDetailDTO surgeryDetailDTO = new ConceptDetailDTO();
|
|
|
- BeanUtil.copyProperties(surgeryTreatmentDetailList.get(0), surgeryDetailDTO);
|
|
|
- retMap.put("surgeryTreatment", surgeryDetailDTO);
|
|
|
+ ConceptIntroduceDTO surgeryTreatmentDetail = conceptDetailFacade.getConceptDetail(conceptIntroduceVO);
|
|
|
+ if (surgeryTreatmentDetail != null && ListUtil.isNotEmpty(surgeryTreatmentDetail.getDetails())) {
|
|
|
+ retMap.put("surgeryTreatment", surgeryTreatmentDetail.getDetails().get(0));
|
|
|
} else {
|
|
|
retMap.put("surgeryTreatment", null);
|
|
|
}
|
|
@@ -121,9 +114,10 @@ public class TreatmentFacade {
|
|
|
medicitionClass.setSubdrugsLibType(LexiconTypeEnum.DRUG_CATEGORY_SMALL.getKey());
|
|
|
medicitionClass.setSubdrugsType(ConceptTypeEnum.Drug_Category_Small.getKey());
|
|
|
if (cateBigConcept != null) {
|
|
|
- conceptBaseVO.setLibType(LexiconTypeEnum.DRUG_CATEGORY_BIG.getKey());
|
|
|
- conceptBaseVO.setName(cateBigConcept.getLibName());
|
|
|
- if (conceptDetailFacade.exist(conceptBaseVO)) {
|
|
|
+ conceptIntroduceVO = new ConceptIntroduceVO();
|
|
|
+ conceptIntroduceVO.setName(cateBigConcept.getLibName());
|
|
|
+ conceptIntroduceVO.setLibType(LexiconTypeEnum.DRUG_CATEGORY_BIG.getKey());
|
|
|
+ if (conceptDetailFacade.exist(conceptIntroduceVO)) {
|
|
|
medicitionClass.setShowInfo("1");
|
|
|
} else {
|
|
|
medicitionClass.setShowInfo("0");
|
|
@@ -139,7 +133,8 @@ public class TreatmentFacade {
|
|
|
if (drugConcept != null) {
|
|
|
medicition.setConceptId(drugConcept.getId());
|
|
|
}
|
|
|
- medicition.setLibType(ConceptTypeEnum.Drug.getKey());
|
|
|
+ medicition.setLibType(LexiconTypeEnum.DRUGS.getKey());
|
|
|
+ medicition.setType(ConceptTypeEnum.Drug.getKey());
|
|
|
if (drugDetailMap != null && drugDetailMap.containsKey(medicition.getMedicitionName())) {
|
|
|
medicition.setShowInfo("1");
|
|
|
} else {
|