From c820d3303f33268cf19a7b01171099afaae70127 Mon Sep 17 00:00:00 2001 From: liquanyu Date: Fri, 4 Sep 2020 09:24:28 +0800 Subject: [PATCH] =?UTF-8?q?=E5=84=BF=E7=AB=A5=E8=BF=BD=E8=AE=BF=E5=8C=BA?= =?UTF-8?q?=E5=9F=9F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/lyms/platform/biz/service/BabyBookbuildingService.java | 9 +++++++++ .../operate/web/service/impl/BabyAfterVisitServiceImpl.java | 4 ++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/platform-biz-patient-service/src/main/java/com/lyms/platform/biz/service/BabyBookbuildingService.java b/platform-biz-patient-service/src/main/java/com/lyms/platform/biz/service/BabyBookbuildingService.java index 644e6ae..888dd13 100644 --- a/platform-biz-patient-service/src/main/java/com/lyms/platform/biz/service/BabyBookbuildingService.java +++ b/platform-biz-patient-service/src/main/java/com/lyms/platform/biz/service/BabyBookbuildingService.java @@ -106,6 +106,15 @@ public class BabyBookbuildingService { return CollectionUtils.isNotEmpty(list) ? list.get(0) : null; } + + public BabyModel queryBabyById(String id) { + BabyModelQuery babyQuery = new BabyModelQuery(); + babyQuery.setId(id); + MongoQuery query = babyQuery.convertToQuery(); + List list = babyBookBuildingDao.queryBabyWithQuery(query); + return CollectionUtils.isNotEmpty(list) ? list.get(0) : null; + } + public List queryBabyBuildByCond(BabyModelQuery babyQuery,String sortkey,Sort.Direction sort) { MongoQuery query = babyQuery.convertToQuery(); if (StringUtils.isNotEmpty(babyQuery.getNeed())) { diff --git a/platform-operate-api/src/main/java/com/lyms/platform/operate/web/service/impl/BabyAfterVisitServiceImpl.java b/platform-operate-api/src/main/java/com/lyms/platform/operate/web/service/impl/BabyAfterVisitServiceImpl.java index 196a467..76f54a6 100644 --- a/platform-operate-api/src/main/java/com/lyms/platform/operate/web/service/impl/BabyAfterVisitServiceImpl.java +++ b/platform-operate-api/src/main/java/com/lyms/platform/operate/web/service/impl/BabyAfterVisitServiceImpl.java @@ -182,7 +182,7 @@ public class BabyAfterVisitServiceImpl implements BabyAfterVisitService { if (request.isArea()) { objectMap.put("hospitalName", CommonsHelper.getHospitalName(model.getHospitalId(), organizationService)); - BabyModel babyModel = babyBookbuildingService.queryBabyBuildById(model.getBabyId()); + BabyModel babyModel = babyBookbuildingService.queryBabyById(model.getBabyId()); String address = ""; if (babyModel != null) { @@ -510,7 +510,7 @@ public class BabyAfterVisitServiceImpl implements BabyAfterVisitService { if (request.isArea()) { objectMap.put("hospitalName", CommonsHelper.getHospitalName(model.getHospitalId(), organizationService)); - BabyModel babyModel = babyBookbuildingService.queryBabyBuildById(model.getBabyId()); + BabyModel babyModel = babyBookbuildingService.queryBabyById(model.getBabyId()); if (babyModel != null) { objectMap.put("address", CommonsHelper.getResidence(babyModel.getProvinceId(), babyModel.getCityId(), -- 1.8.3.1