Commit 7e7ffd406e05c637a0360103945f0ed7034e266d
1 parent
8c1f79146d
Exists in
master
and in
6 other branches
增加patientId
Showing 2 changed files with 27 additions and 7 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/service/impl/PostReviewServiceImpl.java
View file @
7e7ffd4
... | ... | @@ -55,7 +55,7 @@ |
55 | 55 | |
56 | 56 | if(StringUtils.isNotEmpty(key)) { |
57 | 57 | Criteria criteria = new Criteria(); |
58 | - criteria.orOperator(Criteria.where("username").is(key), Criteria.where("vcCardNo").is(key), Criteria.where("phone").is(key)); | |
58 | + criteria.orOperator(Criteria.where("username").regex(key), Criteria.where("cardNo").is(key), Criteria.where("phone").is(key)); | |
59 | 59 | List<Patients> patients = mongoUtil.findField(Patients.class, criteria, "id"); |
60 | 60 | if(CollectionUtils.isEmpty(patients)) { |
61 | 61 | return RespBuilder.buildSuccess(new PageResult(0, page, limit, null)); |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/service/impl/ReportServiceImpl.java
View file @
7e7ffd4
... | ... | @@ -1217,16 +1217,36 @@ |
1217 | 1217 | } |
1218 | 1218 | } |
1219 | 1219 | System.out.println("==========="); |
1220 | - for (Map.Entry<String, List<Map<String, Object>>> map : userCheckInfo.entrySet()) { | |
1221 | - System.out.println(map.getKey() + " : " + map.getValue()); | |
1222 | - } | |
1223 | - | |
1224 | 1220 | Map<Integer, Integer> countMap = new HashMap<>(); |
1225 | 1221 | for (int i = 1; i < 14; i++) { |
1226 | 1222 | countMap.put(i, 0); |
1227 | 1223 | } |
1228 | - for (Map<String,Object> map : datas) { | |
1229 | - | |
1224 | + Set<Map.Entry<String, List<Map<String, Object>>>> entries = userCheckInfo.entrySet(); | |
1225 | + for (Map.Entry<String, List<Map<String, Object>>> entry : entries) { | |
1226 | + List<Map<String, Object>> value = entry.getValue(); | |
1227 | + if(value.size() == 1) { | |
1228 | + countMap.put(1, countMap.get(1) + 1); | |
1229 | + } else { | |
1230 | + /** 按照分娩时间分组 */ | |
1231 | + /** key=pid value=count */ | |
1232 | + Map<Date, Integer> tempMap = new HashMap<>(); | |
1233 | + Integer other = 0; | |
1234 | + Date otherDate = new Date(); | |
1235 | + for (Map<String, Object> map : value) { | |
1236 | + Date fmDate = (Date) map.get("fmDate"); | |
1237 | + if(fmDate == null) { | |
1238 | + ++other; | |
1239 | + continue; | |
1240 | + } | |
1241 | + if(tempMap.containsKey(fmDate)) { | |
1242 | + tempMap.put(fmDate, tempMap.get(fmDate) + 1); | |
1243 | + } else { | |
1244 | + tempMap.put(fmDate, 1); | |
1245 | + } | |
1246 | + } | |
1247 | + tempMap.put(otherDate, other); | |
1248 | + System.out.println(">>> " + tempMap); | |
1249 | + } | |
1230 | 1250 | } |
1231 | 1251 | |
1232 | 1252 | List<Map<String,Object>> restList = new ArrayList<>(); |