diff --git a/platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/AntexDoctorStatistController.java b/platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/AntexDoctorStatistController.java index 99d7649..b2f9ee8 100644 --- a/platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/AntexDoctorStatistController.java +++ b/platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/AntexDoctorStatistController.java @@ -498,7 +498,7 @@ public class AntexDoctorStatistController extends BaseController { } /** - * 产检医生统计 + * 产检医生统计导出 * * @param startDate 建档开始时间 * @param endDate 建档结束时间 @@ -515,10 +515,10 @@ public class AntexDoctorStatistController extends BaseController { columName.put("doctorName", "产检医生"); columName.put("inspectTime", "产检人次"); columName.put("inspectPeople", "产检人数"); - columName.put("twice", "两次"); - columName.put("twiceProportion", ""); - columName.put("fiveTimes", ""); - columName.put("fiveTimeProportion", ""); + columName.put("twice", "两次(含)以上人数"); + columName.put("twiceProportion", "两次(含)以上比例"); + columName.put("fiveTimes", "五次(含)以上人数"); + columName.put("fiveTimeProportion", "五次(含)以上比例"); try { ExcelUtil.toExcel(response.getOutputStream(), data, columName); diff --git a/platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/BabyCheckController.java b/platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/BabyCheckController.java index 8e08aff..d8ab66f 100644 --- a/platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/BabyCheckController.java +++ b/platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/BabyCheckController.java @@ -196,7 +196,6 @@ public class BabyCheckController extends BaseController{ @ResponseBody public BaseObjectResponse getBaseConfig(){ return babyCheckFacade.getBaseConfig(); - } /** diff --git a/platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/BabyCheckFacade.java b/platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/BabyCheckFacade.java index 8ceae2b..f84322d 100644 --- a/platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/BabyCheckFacade.java +++ b/platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/BabyCheckFacade.java @@ -246,9 +246,9 @@ public class BabyCheckFacade { public BaseResponse addBabyCheck(BabyCheckRequest request, Integer userId) { /** 验证产检券是否可用 可用就改为已使用状态 */ - if(org.apache.commons.lang3.StringUtils.isNotBlank(request.getCouponCode()) && request.getCouponType() != null) { + if (org.apache.commons.lang3.StringUtils.isNotBlank(request.getCouponCode()) && request.getCouponType() != null) { BaseObjectResponse resp = couponService.validate(request.getCouponCode(), request.getCouponType(), autoMatchFacade.getHospitalId(userId)); - if(resp.getErrorcode() != 0) { + if (resp.getErrorcode() != 0) { return resp; } } @@ -297,7 +297,7 @@ public class BabyCheckFacade { model = babyCheckService.addBabyCheck(model); /** 使用优惠券 */ - if(org.apache.commons.lang3.StringUtils.isNotBlank(request.getCouponCode()) && request.getCouponType() != null) { + if (org.apache.commons.lang3.StringUtils.isNotBlank(request.getCouponCode()) && request.getCouponType() != null) { couponService.use(autoMatchFacade.getHospitalId(userId), request.getCouponCode(), userId, model.getId()); } @@ -480,7 +480,27 @@ public class BabyCheckFacade { BaseObjectResponse br = new BaseObjectResponse(); BabyBasicResult base = new BabyBasicResult(); Map resMap = new HashMap<>(); - getBabyModel(id, base); + + BabyModel model = getBabyModel(id, base); + BabyModelQuery babyQuery = new BabyModelQuery(); + babyQuery.setPid(model.getPid()); + babyQuery.setYn(YnEnums.YES.getId()); + + //查询儿童的基本信息 + List models = babyBookbuildingService.queryBabyBuildByCond(babyQuery); + + if (CollectionUtils.isNotEmpty(models)) { + + PatientsQuery patientsQuery = new PatientsQuery(); + patientsQuery.setId(model.getParentId()); + patientsQuery.setYn(YnEnums.YES.getId()); + + List personModels = patientsService.queryPatient(patientsQuery); + if (CollectionUtils.isNotEmpty(personModels)) { + Patients personModel = personModels.get(0); + base.setPregnantCertificateTypeId(personModel.getHcertificateTypeId()); + } + } resMap.put("baseInfo", base); br.setData(resMap); br.setErrorcode(ErrorCodeConstants.SUCCESS); @@ -599,7 +619,7 @@ public class BabyCheckFacade { base.setCardNo(model.getMcertNo()); base.setMonthAge(DateUtil.getBabyMonthAge(model.getBirth(), new Date())); base.setBirthday(DateUtil.getyyyy_MM_dd(model.getBirth())); - base.setSourceId(org.apache.commons.lang.StringUtils.isNotEmpty(model.getSource())?model.getSource():model.getId()); + base.setSourceId(org.apache.commons.lang.StringUtils.isNotEmpty(model.getSource()) ? model.getSource() : model.getId()); if (model.getPid() != null) { //诊断 List list = getBabyLastDiagnose(model.getPid()); @@ -792,10 +812,10 @@ public class BabyCheckFacade { babyQuery.setYn(YnEnums.YES.getId()); /** 处理优惠券查询 */ - if(StringUtils.isNotEmpty(coupon)) { + if (StringUtils.isNotEmpty(coupon)) { Map m = couponMapper.findUrl(coupon); Object personId = m.get("user_id"); - if(personId != null) { + if (personId != null) { babyQuery.setPid(personId.toString()); } } @@ -813,25 +833,23 @@ public class BabyCheckFacade { List models = babyBookbuildingService.queryBabyBuildByCond(babyQuery); - if (CollectionUtils.isEmpty(models) && StringUtils.isNotEmpty(vcCardNo)) - { - if ("4".equals(HIS_VERSION)) { - List> hisPatient = qhdfyHisService.getPatientInfoList(vcCardNo); - - if (CollectionUtils.isNotEmpty(hisPatient)) { - Map babyHis = hisPatient.get(0); - if (babyHis != null && babyHis.get("phone") != null && StringUtils.isNotEmpty(babyHis.get("phone").toString())) { - babyQuery.setPhoneOrcardNo(null); //手机号码或者身份证号码 - babyQuery.setVcCardNo(null); - babyQuery.setMphone(babyHis.get("phone").toString()); - models = babyBookbuildingService.queryBabyBuildByCond(babyQuery); - } - } - } + if (CollectionUtils.isEmpty(models) && StringUtils.isNotEmpty(vcCardNo)) { + if ("4".equals(HIS_VERSION)) { + List> hisPatient = qhdfyHisService.getPatientInfoList(vcCardNo); + + if (CollectionUtils.isNotEmpty(hisPatient)) { + Map babyHis = hisPatient.get(0); + if (babyHis != null && babyHis.get("phone") != null && StringUtils.isNotEmpty(babyHis.get("phone").toString())) { + babyQuery.setPhoneOrcardNo(null); //手机号码或者身份证号码 + babyQuery.setVcCardNo(null); + babyQuery.setMphone(babyHis.get("phone").toString()); + models = babyBookbuildingService.queryBabyBuildByCond(babyQuery); + } + } + } } - if (CollectionUtils.isNotEmpty(models)) - { + if (CollectionUtils.isNotEmpty(models)) { for (BabyModel model : models) { if (model != null && model.getHospitalId() != null && hList.contains(hospitalId)) { isBuild = true; @@ -882,7 +900,6 @@ public class BabyCheckFacade { } - br.setData(result); br.setErrorcode(ErrorCodeConstants.SUCCESS); br.setErrormsg("成功"); @@ -1142,6 +1159,7 @@ public class BabyCheckFacade { * 身高别体重》M-2s && 年龄别身高小于M-2s * 4.慢性严重营养不良 * 身高别体重小于M-2s && 年龄别身高小于M-2s。 + * * @return */ public List getBabyGrowthEvaluate(Double height, Integer sex, String birth, Double weight) { @@ -1235,18 +1253,17 @@ public class BabyCheckFacade { date = DateUtil.parseYMD(checkDate); } - boolean isShowNavel = false; - int monthes = DateUtil.getBabyAgeMonth(birthDate,date); - if (monthes == 1 || monthes == 3) - { - isShowNavel = true; + boolean isShowNavel = false; + int monthes = DateUtil.getBabyAgeMonth(birthDate, date); + if (monthes == 1 || monthes == 3) { + isShowNavel = true; } String ageStr = DateUtil.getBabyMonthAge(birthDate, date); BaseObjectResponse objectResponse = new BaseObjectResponse(); - Map map = new HashMap<>(); - map.put("monthAge",ageStr); - map.put("isShowNavel",isShowNavel); + Map map = new HashMap<>(); + map.put("monthAge", ageStr); + map.put("isShowNavel", isShowNavel); objectResponse.setData(map); objectResponse.setErrorcode(ErrorCodeConstants.SUCCESS); objectResponse.setErrormsg("成功"); diff --git a/platform-operate-api/src/main/webapp/WEB-INF/web.xml b/platform-operate-api/src/main/webapp/WEB-INF/web.xml index a5513ae..9cdd433 100644 --- a/platform-operate-api/src/main/webapp/WEB-INF/web.xml +++ b/platform-operate-api/src/main/webapp/WEB-INF/web.xml @@ -13,7 +13,7 @@ version="2.5" xsi:schemaLocation="http://java.sun.com/xml/ns/javaee http://java.sun.com/xml/ns/javaee/web-app_2_5.xsd"> -