Browse Source

主诉中的诊断参与推送

kongwz 4 years ago
parent
commit
a7c86232d7
1 changed files with 10 additions and 0 deletions
  1. 10 0
      src/main/java/com/diagbot/facade/NeoFacade.java

+ 10 - 0
src/main/java/com/diagbot/facade/NeoFacade.java

@@ -257,12 +257,21 @@ public class NeoFacade {
         Integer sex = pushVO.getSex();
         List<String> presentDiags = Lists.newArrayList();
         PresentPushVo presentPushVo = pushVO.getPresentPushVo();
+        ChiefPushVo chiefPushVo = pushVO.getChiefPushVo();
         if(presentPushVo != null){
             List<Diag> diags = presentPushVo.getDiags();
             if(ListUtil.isNotEmpty(diags)){
                 presentDiags = diags.stream().map(x -> x.getName()).collect(Collectors.toList());
             }
         }
+        if(chiefPushVo != null){
+            List<Diag> diags = chiefPushVo.getDiags();
+            if(ListUtil.isNotEmpty(diags) ){
+                List<String> collect = diags.stream().map(x -> x.getName()).collect(Collectors.toList());
+                presentDiags.retainAll(collect);
+                presentDiags.addAll(collect);
+            }
+        }
         List<PD> pds = pushVO.getChiefPushVo().getPds();
         PD pd = null;
         if(ListUtil.isNotEmpty(pds)){
@@ -344,6 +353,7 @@ public class NeoFacade {
             }
             lis_dis_new = lis_dis_new.stream().distinct().collect(Collectors.toList());
         }else {
+            lis_dis.addAll(presentDiags);
             lis_dis_new =lis_dis;
         }
         return lis_dis_new;