From fe6e20ff969959fffe4c87a14165d82536d0f8cb Mon Sep 17 00:00:00 2001 From: liquanyu Date: Tue, 15 Sep 2020 14:33:31 +0800 Subject: [PATCH] =?UTF-8?q?=E5=A4=A7=E5=90=8C=E5=88=9D=E8=AF=8A=E6=89=93?= =?UTF-8?q?=E5=8D=B0?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../platform/operate/web/facade/ViewFacade.java | 55 +++++++++------------- 1 file changed, 22 insertions(+), 33 deletions(-) diff --git a/platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/ViewFacade.java b/platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/ViewFacade.java index fc2dbfe..471145b 100644 --- a/platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/ViewFacade.java +++ b/platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/ViewFacade.java @@ -385,57 +385,46 @@ public class ViewFacade { public Map getPrintPatientViewData(Patients data, String id) { - Map map = new HashMap<>(); + Map map = new LinkedHashMap<>(); map.put("id", data.getId()); /* 孕妇基础数据 */ map.put("username", data.getUsername()); + map.put("age", DateUtil.getAge(data.getBirth())); map.put("birth", DateUtil.getyyyy_MM_dd(data.getBirth())); - map.put("age", UnitUtils.unitSplice(DateUtil.getAge(data.getBirth()), UnitConstants.SUI)); - - - /* 孕妇联系方式 */ -// map.put("residence", CommonsHelper.getResidence(data.getProvinceId(), data.getCityId(), -// data.getAreaId(), data.getStreetId(), data.getAddress(), basicConfigService)); - map.put("register", CommonsHelper.getResidence(data.getProvinceRegisterId(), data.getCityRegisterId(), - data.getAreaRegisterId(), data.getStreetRegisterId(), data.getAddressRegister(), basicConfigService)); + map.put("register", CommonsHelper.getResidence(data.getProvinceId(), data.getCityId(), + data.getAreaId(), data.getStreetId(), data.getAddress(), basicConfigService)); +// map.put("register", CommonsHelper.getResidence(data.getProvinceRegisterId(), data.getCityRegisterId(), +// data.getAreaRegisterId(), data.getStreetRegisterId(), data.getAddressRegister(), basicConfigService)); // map.put("postRest", CommonsHelper.getResidence(data.getProvincePostRestId(), data.getCityPostRestId(), // data.getAreaPostRestId(), data.getStreetPostRestId(), data.getChildExtAddrs(), data.getAddressPostRest(), basicConfigService)); + map.put("pprofessionType", getBasicConfig(data.getPprofessionTypeId())); - map.put("hprofessionType", getBasicConfig(data.getHprofessionTypeId())); - /* 丈夫信息 */ - map.put("husbandName", data.getHusbandName()); + map.put("LevelType",data.getLevelTypeId() == null ? "" : data.getLevelTypeId()); + map.put("marriageAge",data.getMarriageAge() == null ? "" : data.getMarriageAge()); + map.put("marriageStatus",data.getMarriageStatus() == null ? "" : data.getMarriageStatus()); + map.put("marriageCheck",data.getMarriageCheck() == null ? "" : data.getMarriageCheck()); + map.put("contraceptionType",data.getContraceptionType()); - map.put("husbandBirth", DateUtil.getyyyy_MM_dd(data.getHusbandBirth())); + /* 丈夫信息 */ + map.put("husbandName", data.getHusbandName()); map.put("husbandAge", DateUtil.getAge(data.getHusbandBirth())); - map.put("hregister", CommonsHelper.getResidence(data.getHprovinceRegisterId(), data.getHcityRegisterId(), data.getHareaRegisterId(), data.getHstreetRegisterId(), data.getHaddressRegister(), basicConfigService)); + map.put("hprofessionType", getBasicConfig(data.getHprofessionTypeId())); + map.put("hmarriageAge",data.getHmarriageAge() == null ? "" : data.getHmarriageAge()); + map.put("hphone", data.getHusbandPhone() == null ? "" : data.getHusbandPhone()); + map.put("healthStatus",data.getHealthStatus() == null ? "" : data.getHealthStatus()); - map.put("LevelType",getBasicConfig(data.getLevelTypeId())); - map.put("marriageStatus",data.getMarriageStatus() == null ? "" : data.getMarriageStatus() == 1 ? "初婚" : (data.getMarriageStatus() == 2 ? "再婚" : "其他")); - map.put("marriageCheck",data.getMarriageCheck() == null ? "" : data.getMarriageCheck() == 1 ? "是" : "否"); - StringBuilder sb = new StringBuilder(); - if (data.getContraceptionType() != null && data.getContraceptionType().size() > 0) - { - sb.append(data.getContraceptionType().get("wby") != null && data.getContraceptionType().get("wby") == true ? "未避孕 " : ""); - sb.append(data.getContraceptionType().get("kfby") != null && data.getContraceptionType().get("kfby") == true ? "口服避孕药 " : ""); - sb.append(data.getContraceptionType().get("byt") != null && data.getContraceptionType().get("byt") == true ? "避孕套 " : ""); - sb.append(data.getContraceptionType().get("bym") != null && data.getContraceptionType().get("bym") == true ? "避孕膜 " : ""); - sb.append(data.getContraceptionType().get("qt") != null && data.getContraceptionType().get("qt") == true ? data.getContraceptionOther()+" " : ""); - } - map.put("contraceptionType",sb.toString()); - map.put("hmarriageStatus",data.getHmarriageStatus() == null ? "" : data.getHmarriageStatus() == 1 ? "初婚" : (data.getHmarriageStatus() == 2 ? "再婚" : "其他")); - map.put("healthStatus",data.getHealthStatus()); - map.put("smoke",data.getSmoke() == null ? "" : data.getSmoke() == 1 ? "否" : "是"); + map.put("smoke",data.getSmoke() == null ? "" : data.getSmoke()); map.put("smokeNum",(data.getSmoke() != null && data.getSmoke() == 2) ? data.getSmokeNum() : ""); - map.put("drinkWine",data.getDrinkWine() == null ? "" : data.getDrinkWine() == 1 ? "偶尔" : (data.getDrinkWine() == 2 ? "经常" : "否")); - map.put("hLevelType",getBasicConfig(data.getHlevelTypeId())); - map.put("hmarriageAge",data.getHmarriageAge() == null ? "" : data.getHmarriageAge()); + map.put("drinkWine",data.getDrinkWine() == null ? "" : data.getDrinkWine()); + map.put("hLevelType",data.getHlevelTypeId() == null ? "" : data.getHlevelTypeId()); + map.put("pastHistory",data.getPastHistory() == null ? "" : data.getPastHistory()); map.put("familyHistory",data.getFamilyHistory() == null ? "" : data.getFamilyHistory()); map.put("other",data.getOther() == null ? "" :data.getOther()); -- 1.8.3.1