Commit 75292f9623c7a7dfbe0ac903365e5d53c29618cf
1 parent
982dfa3c55
Exists in
master
and in
6 other branches
助产机构报表
Showing 1 changed file with 14 additions and 2 deletions
platform-dal/src/main/java/com/lyms/platform/query/BabyModelQuery.java
View file @
75292f9
... | ... | @@ -931,10 +931,22 @@ |
931 | 931 | } |
932 | 932 | } |
933 | 933 | |
934 | - | |
935 | 934 | if (null != babyWeightStart) { |
936 | - c = Criteria.where("babyWeight").gte(babyWeightStart); | |
935 | + if (null != c) { | |
936 | + c = c.and("babyWeight").gte(babyWeightStart); | |
937 | + } else { | |
938 | + c = Criteria.where("babyWeight").gte(babyWeightStart); | |
939 | + } | |
937 | 940 | } |
941 | + | |
942 | + if (null != babyWeightEnd) { | |
943 | + if (null != c) { | |
944 | + c = c.lte(babyWeightEnd); | |
945 | + } else { | |
946 | + c = Criteria.where("babyWeight").lte(babyWeightEnd); | |
947 | + } | |
948 | + } | |
949 | + | |
938 | 950 | |
939 | 951 | if (null != buildDateStart) { |
940 | 952 | if (null != c) { |