diff --git a/platform-dal/src/main/java/com/lyms/platform/query/PatientsQuery.java b/platform-dal/src/main/java/com/lyms/platform/query/PatientsQuery.java index 2565bcc..e3430eb 100644 --- a/platform-dal/src/main/java/com/lyms/platform/query/PatientsQuery.java +++ b/platform-dal/src/main/java/com/lyms/platform/query/PatientsQuery.java @@ -149,6 +149,9 @@ public class PatientsQuery extends BaseQuery implements IConvertToNativeQuery { //区域来源 private String source; + //区域来源 + private Boolean extSource; + private String desc; //查询号 private String queryNo; @@ -163,6 +166,14 @@ public class PatientsQuery extends BaseQuery implements IConvertToNativeQuery { private Integer buildDaysStart; private Integer buildDaysEnd; + public Boolean isExtSource() { + return extSource; + } + + public void setExtSource(Boolean extSource) { + this.extSource = extSource; + } + public boolean isFace() { return isFace; } @@ -1182,6 +1193,13 @@ public class PatientsQuery extends BaseQuery implements IConvertToNativeQuery { condition = condition.and("face", true, MongoOper.EXISTS); } + + if (extSource != null) { + condition = condition.and("source", extSource, MongoOper.EXISTS); + } + + + if (isScreenResult) { condition = condition.and("screenResult", true, MongoOper.EXISTS); } diff --git a/platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/PatientFacade.java b/platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/PatientFacade.java index b114fa0..90b982c 100644 --- a/platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/PatientFacade.java +++ b/platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/PatientFacade.java @@ -469,6 +469,16 @@ public class PatientFacade { fmHospitalList.retainAll(orgId); } } + else + { + //没有选择分娩医院 并且未产妇查询的时候 就只查询主档案 + if (type == 3) + { + patientsQuery.setExtSource(false); + } + } + + if (com.lyms.platform.common.utils.StringUtils.isNotEmpty(riskPatientsQueryRequest.getFmHospital())) { patientsQuery.setFmHospital(riskPatientsQueryRequest.getFmHospital()); } else {