|
@@ -19,6 +19,7 @@ import com.diagbot.dto.RespDTO;
|
|
|
import com.diagbot.entity.Concept;
|
|
|
import com.diagbot.entity.Relation;
|
|
|
import com.diagbot.entity.RelationOrder;
|
|
|
+import com.diagbot.enums.IsDeleteEnum;
|
|
|
import com.diagbot.enums.LexiconTypeEnum;
|
|
|
import com.diagbot.exception.CommonErrorCode;
|
|
|
import com.diagbot.exception.CommonException;
|
|
@@ -202,8 +203,9 @@ public class RelationContactFacade extends RelationServiceImpl {
|
|
|
relationNodeDTO.setConceptTypeId(concept.getLibType());
|
|
|
relationNodeDTO.setConceptTypeName(LexiconTypeEnum.getName(concept.getLibType().intValue()));
|
|
|
relationNodeDTO.setConceptNameType(concept.getLibName()+"("+LexiconTypeEnum.getName(concept.getLibType().intValue())+")");
|
|
|
+ relationNodeDTO.setIsDeletedConcept(concept.getIsDeleted());
|
|
|
|
|
|
- relationNodeDTO.setNodeList(repairRelationDataForQuery(relationContactDetailVO.getConceptId(), relationContactDetailVO.getRelationId(),null));
|
|
|
+ relationNodeDTO.setNodeList(repairRelationDataForQuery(relationContactDetailVO.getConceptId(), relationContactDetailVO.getRelationId(),null,concept.getIsDeleted()));
|
|
|
|
|
|
return relationNodeDTO;
|
|
|
}
|
|
@@ -213,9 +215,10 @@ public class RelationContactFacade extends RelationServiceImpl {
|
|
|
* @param conceptId
|
|
|
* @param relationId
|
|
|
* @param hookConceptIds
|
|
|
+ * @param isDeletedParent
|
|
|
* @return
|
|
|
*/
|
|
|
- private List<RelationNodeDTO> repairRelationDataForQuery(Long conceptId,Long relationId,List<Long> hookConceptIds){
|
|
|
+ private List<RelationNodeDTO> repairRelationDataForQuery(Long conceptId,Long relationId,List<Long> hookConceptIds,String isDeletedParent){
|
|
|
if(hookConceptIds==null){
|
|
|
hookConceptIds = new ArrayList<>();
|
|
|
hookConceptIds.add(conceptId);
|
|
@@ -228,12 +231,13 @@ public class RelationContactFacade extends RelationServiceImpl {
|
|
|
i.setConceptNameType(i.getConceptName()+"("+LexiconTypeEnum.getName(i.getConceptTypeId().intValue())+")");
|
|
|
i.setParentConceptTypeName(LexiconTypeEnum.getName(i.getParentConceptTypeId().intValue()));
|
|
|
i.setParentConceptNameType(i.getParentConceptName()+"("+LexiconTypeEnum.getName(i.getParentConceptTypeId().intValue())+")");
|
|
|
+ i.setIsDeletedConcept(isDeletedParent.equals(IsDeleteEnum.Y.getKey())?IsDeleteEnum.Y.getKey():i.getIsDeletedConcept());
|
|
|
|
|
|
if(!hookConceptIds.contains(i.getConceptId())){
|
|
|
List<Long> hookConceptIds_ = new ArrayList<>();
|
|
|
hookConceptIds_.addAll(hookConceptIds);
|
|
|
hookConceptIds_.add(i.getConceptId());
|
|
|
- i.setNodeList(repairRelationDataForQuery(i.getConceptId(), relationId,hookConceptIds_));
|
|
|
+ i.setNodeList(repairRelationDataForQuery(i.getConceptId(), relationId,hookConceptIds_,i.getIsDeletedConcept()));
|
|
|
}
|
|
|
}
|
|
|
|