ソースを参照

预问诊常用标签年龄和性别过滤

zhoutg 5 年 前
コミット
68fa7a8923

+ 6 - 0
prec-service/src/main/java/com/diagbot/facade/QuestionUsualFacade.java

@@ -63,11 +63,17 @@ public class QuestionUsualFacade {
                     .map(ConceptBaseDTO::getName)
                     .collect(Collectors.toList());
             //与question标签匹配
+            List<Integer> sexList = new ArrayList<>();
+            sexList.add(3);
+            sexList.add(questionUsualVO.getSexType());
             QueryWrapper<QuestionInfo> questionInfoQueryWrapper = new QueryWrapper<>();
             questionInfoQueryWrapper.eq("is_deleted", IsDeleteEnum.N.getKey())
                     .in("tag_name", conceptName)
                     .ne("tag_type", 8)
                     .eq("item_type", 0)
+                    .in("sex_type", sexList)
+                    .le("age_begin", questionUsualVO.getAge())
+                    .ge("age_end", questionUsualVO.getAge())
                     .eq("type", type);
             List<QuestionInfo> questionInfoList = questionFacade.list(questionInfoQueryWrapper);
             Map<String, QuestionInfo> questionInfoMap