Commit 4eadedbd62bf8347b8d102c9cf4e66aebefe6693
1 parent
c37191e0a2
Exists in
master
and in
1 other branch
update
Showing 1 changed file with 17 additions and 1 deletions
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/BabyBookbuildingFacade.java
View file @
4eadedb
| ... | ... | @@ -3202,8 +3202,24 @@ |
| 3202 | 3202 | babyQuery.setBirthEnd(new Date(DateUtil.parseYMD(birth).getTime() + 24 * 60 * 60 * 1000 - 1)); |
| 3203 | 3203 | } |
| 3204 | 3204 | babyQuery.setSex(sex); |
| 3205 | + List <Map> mapList = new ArrayList <>(); | |
| 3206 | + | |
| 3205 | 3207 | List <BabyModel> models = babyBookbuildingService.queryBabyBuildByCond(babyQuery, "created", Sort.Direction.DESC); |
| 3206 | - br.setData(models); | |
| 3208 | + for (int i = 0; i <models.size() ; i++) { | |
| 3209 | + try { | |
| 3210 | + Map<String,String> map = new HashMap(); | |
| 3211 | + map.put("birth", DateUtil.getYyyyMmDd(models.get(i).getBirth())); | |
| 3212 | + map.put("babyName", models.get(i).getName()); | |
| 3213 | + map.put("sex", SexEnum.getTextById(models.get(i).getSex())); | |
| 3214 | + map.put("mphone", models.get(i).getMphone()); | |
| 3215 | + map.put("id", models.get(i).getId()); | |
| 3216 | + mapList.add(map); | |
| 3217 | + } catch (Exception e) { | |
| 3218 | + e.printStackTrace(); | |
| 3219 | + continue; | |
| 3220 | + } | |
| 3221 | + } | |
| 3222 | + br.setData(mapList); | |
| 3207 | 3223 | br.setErrorcode(ErrorCodeConstants.SUCCESS); |
| 3208 | 3224 | br.setErrormsg("成功"); |
| 3209 | 3225 | return br; |