Commit a17341f25c9c7264c298ce97b71c92ad363ffa73
1 parent
f1631aac3c
Exists in
master
and in
6 other branches
追访
Showing 1 changed file with 12 additions and 10 deletions
platform-dal/src/main/java/com/lyms/platform/query/BabyModelQuery.java
View file @
a17341f
... | ... | @@ -93,7 +93,7 @@ |
93 | 93 | /** |
94 | 94 | * 数据状态 true:排除孕妇分娩自动建档 |
95 | 95 | */ |
96 | - private boolean dataStatus = false; | |
96 | + private Boolean dataStatus; | |
97 | 97 | |
98 | 98 | //母亲证件号 |
99 | 99 | private String mcertNo; |
100 | 100 | |
... | ... | @@ -312,11 +312,11 @@ |
312 | 312 | this.buildType = buildType; |
313 | 313 | } |
314 | 314 | |
315 | - public boolean isDataStatus() { | |
315 | + public Boolean getDataStatus() { | |
316 | 316 | return dataStatus; |
317 | 317 | } |
318 | 318 | |
319 | - public void setDataStatus(boolean dataStatus) { | |
319 | + public void setDataStatus(Boolean dataStatus) { | |
320 | 320 | this.dataStatus = dataStatus; |
321 | 321 | } |
322 | 322 | |
323 | 323 | |
... | ... | @@ -639,14 +639,16 @@ |
639 | 639 | |
640 | 640 | if (-1 != yn) { |
641 | 641 | condition = condition.and("yn", yn, MongoOper.IS); |
642 | - } | |
643 | - | |
644 | - if (dataStatus) {//分娩自动建档 | |
645 | - condition = condition.and("dataStatus", 1, MongoOper.NE); | |
646 | 642 | }else{ |
647 | - mongoCondits.add(new MongoCondition("yn", 1, MongoOper.IS)); | |
648 | - mongoCondits.add(new MongoCondition("dataStatus", 1, MongoOper.IS).andCondition(new MongoCondition("yn", 0, MongoOper.IS))); | |
649 | - condition = condition.orCondition(mongoCondits.toArray(new MongoCondition[mongoCondits.size()])); | |
643 | + if (dataStatus != null) { | |
644 | + if (dataStatus) {//分娩自动建档 | |
645 | + condition = condition.and("dataStatus", 1, MongoOper.NE); | |
646 | + } else { | |
647 | + mongoCondits.add(new MongoCondition("yn", 1, MongoOper.IS)); | |
648 | + mongoCondits.add(new MongoCondition("dataStatus", 1, MongoOper.IS).andCondition(new MongoCondition("yn", 0, MongoOper.IS))); | |
649 | + condition = condition.orCondition(mongoCondits.toArray(new MongoCondition[mongoCondits.size()])); | |
650 | + } | |
651 | + } | |
650 | 652 | } |
651 | 653 | |
652 | 654 |