Sfoglia il codice sorgente

Merge branch 'dev/mix20191203_staticSearch2' into dev/icss20191209_template

gaodm 5 anni fa
parent
commit
b6cf9ea721

+ 0 - 3
aipt-service/src/main/java/com/diagbot/facade/ConceptFacade.java

@@ -385,9 +385,6 @@ public class ConceptFacade extends ConceptServiceImpl {
         // 是否包含量表
         if (types.contains(LexiconTypeEnum.GAUGE.getKey())) {
             retrievalVO.setHasGauge(true); // 包含量表
-            if (ListUtil.isNotEmpty(types) && types.size() == 1) {
-                retrievalVO.setOnlyGauge(true); // 只有量表
-            }
         }
         for (Integer type : types) {
             // 化验和量表单独处理,不需要遍历

+ 0 - 1
aipt-service/src/main/java/com/diagbot/vo/RetrievalVO.java

@@ -32,6 +32,5 @@ public class RetrievalVO {
     private List<Integer> types; // 指定类型
     private boolean hasLis = false; // 是否搜索化验
     private boolean hasGauge = false; // 是否有量表
-    private boolean onlyGauge = false; // 只有量表
     private List<Integer> typesIn; // 共用需要遍历的类型
 }

+ 5 - 5
aipt-service/src/main/resources/mapper/ConceptMapper.xml

@@ -1067,9 +1067,9 @@
                     )
                 </if>
 
-                -- 量表匹配静态知识,如果只有量表,也同时搜索诊断有关的量表;如果还有其他类型,不搜索诊断相关的量表
+                -- 量表匹配静态知识同时搜索诊断有关的量表;
                 <if test="hasGauge == true">
-                    <if test="typesIn != null and typesIn.size() > 0 || hasLis == true">
+                    <if test="typesIn != null and typesIn.size() > 0 or hasLis == true">
                     union
                     </if>
                     (
@@ -1191,11 +1191,10 @@
                     b2.is_deleted = 'N'
                     AND b1.selfId = b2.concept_id
                     )
-                </if>
 
-                -- 只有量表时还需要根据诊断去查询量表
-                <if test="onlyGauge">
+
                     UNION
+                    (
                     SELECT distinct
                     b2.id conceptId,
                     b2.lib_name `name`,
@@ -1237,6 +1236,7 @@
                     AND b1.selfId = b3.start_id
                     AND b2.id = b3.end_id
                     AND b2.id = b4.concept_id
+                    )
                 </if>
 
             ) a1

+ 7 - 1
tran-service/src/main/java/com/diagbot/facade/PatientInfoDjFacade.java

@@ -433,7 +433,13 @@ public class PatientInfoDjFacade extends PatientInfoServiceImpl {
         //        List<RegisterInfoDTO> rifList = GsonUtil.toList(retJson, RegisterInfoDTO.class);
         List<RegisterInfoDTO> rifList = JSON.parseArray(retJson, RegisterInfoDTO.class);
         System.out.println(rifList);
-        return rifList;
+        if (StringUtil.isBlank(signInVO.getSonHospitalCode())){
+            return rifList;
+        }
+
+        Map<String,List<RegisterInfoDTO>> registerInfoDTOListMap = rifList.stream().collect(Collectors.groupingBy(RegisterInfoDTO::getSonHospitalCode));
+
+        return registerInfoDTOListMap.get(signInVO.getSonHospitalCode());
     }
 
     /**