Commit 66765f81de374a9a6a5f0e2d5cb4149556a2607d

Authored by landong2015
1 parent b86045ac92

拼接单位,修改查看建档接口

Showing 2 changed files with 65 additions and 6 deletions

platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/ViewFacade.java View file @ 66765f8
... ... @@ -69,10 +69,12 @@
69 69 map.put("username", data.getUsername());
70 70 map.put("pcerteType", getBasicConfig(data.getPcerteTypeId()));
71 71 map.put("cardNo", data.getCardNo());
  72 + map.put("phone", data.getPhone());
  73 + map.put("pworkUnit", data.getPworkUnit());
72 74 map.put("pcountry", getBasicConfig(data.getPcountryId()));
73 75 map.put("pnation", getBasicConfig(data.getPnationId()));
74 76 map.put("birth", DateUtil.getyyyy_MM_dd(data.getBirth()));
75   - map.put("age", DateUtil.getAge(data.getBirth()));
  77 + map.put("age", UnitUtils.unitSplice(DateUtil.getAge(data.getBirth()),UnitConstants.SUI));
76 78 map.put("pcensusType", getBasicConfig(data.getPcensusTypeId()));
77 79 map.put("pliveType", getBasicConfig(data.getPliveTypeId()));
78 80 map.put("pprofessionType", getBasicConfig(data.getPprofessionTypeId()));
... ... @@ -84,8 +86,8 @@
84 86 data.getAreaId(), data.getStreetId(), data.getAddress(), basicConfigService));
85 87 map.put("register", CommonsHelper.getResidence(data.getProvinceRegisterId(), data.getCityRegisterId(),
86 88 data.getAreaRegisterId(), data.getStreetRegisterId(), data.getAddressRegister(), basicConfigService));
87   - map.put("postRest", CommonsHelper.getResidence(data.getProvinceId(), data.getCityId(),
88   - data.getAreaId(), data.getStreetId(), data.getAddress(), basicConfigService));
  89 + map.put("postRest", CommonsHelper.getResidence(data.getProvincePostRestId(), data.getCityPostRestId(),
  90 + data.getAreaPostRestId(), data.getStreetPostRestId(), data.getAddressPostRest(), basicConfigService));
89 91  
90 92 /* 丈夫信息 */
91 93 map.put("husbandName", data.getHusbandName());
... ... @@ -167,7 +169,7 @@
167 169 map.put("id",data.getId());
168 170 map.put("username",patients.getUsername());
169 171 map.put("birth", DateUtil.getyyyy_MM_dd(patients.getBirth()));
170   - map.put("age",DateUtil.getAge(patients.getBirth()));
  172 + map.put("age",UnitUtils.unitSplice(DateUtil.getAge(patients.getBirth()),UnitConstants.SUI));
171 173 map.put("phone",patients.getPhone());
172 174 map.put("fmWeek",patients.getFmWeek());
173 175 map.put("dueDate",DateUtil.getyyyy_MM_dd(patients.getDueDate()));
... ... @@ -986,7 +988,7 @@
986 988 map.put("id",data.getId());
987 989 map.put("username",patients.getUsername());
988 990 map.put("birth",DateUtil.getyyyy_MM_dd(patients.getBirth()));
989   - map.put("age",DateUtil.getAge(patients.getBirth()));
  991 + map.put("age",UnitUtils.unitSplice(DateUtil.getAge(patients.getBirth()),UnitConstants.SUI));
990 992 map.put("phone",patients.getPhone());
991 993 map.put("fmWeek",patients.getFmWeek());
992 994 map.put("dueDate",DateUtil.getyyyy_MM_dd(patients.getDueDate()));
993 995  
994 996  
995 997  
996 998  
... ... @@ -1016,12 +1018,68 @@
1016 1018 }
1017 1019  
1018 1020 map.put("hospitalId", hospitalId);
  1021 + map.put("nextCheckTime", DateUtil.getyyyy_MM_dd(data.getNextCheckTime()));
  1022 + map.put("healthStatus", data.getHealthStatus());
  1023 + map.put("psychology", data.getPsychology());
1019 1024  
1020   - String deliverDoctor = "";
  1025 + map.put("weight", UnitUtils.unitSplice(data.getWeight(),UnitConstants.KG));
  1026 + String ssy = "";
  1027 + String szy = "";
  1028 + Map<String, String> chBpMap = JsonUtil.getMap(data.getBp());
  1029 + if (MapUtils.isNotEmpty(chBpMap)) {
  1030 + ssy = chBpMap.get("ssy");
  1031 + szy = chBpMap.get("szy");
  1032 + }
  1033 + map.put("bp", UnitUtils.unitSplice(ssy + "/" + szy,UnitConstants.MMHG));
1021 1034  
  1035 + map.put("breast", data.getBreast());
  1036 + map.put("lochia", data.getLochia());
  1037 + map.put("vulva", data.getVulva());
  1038 + map.put("vagina", data.getVagina());
  1039 + map.put("cervixUteri", data.getCervixUteri());
  1040 + map.put("matrix", data.getMatrix());
  1041 + map.put("fujian", data.getFujian());
  1042 + map.put("wound", data.getWound());
  1043 + map.put("other", data.getOther());
1022 1044  
  1045 + map.put("basin", data.getBasin());
  1046 + map.put("traceElement", data.getTraceElement());
  1047 + map.put("boneDensity", data.getBoneDensity());
  1048 + map.put("ultrasonicExamination", data.getUltrasonicExamination());
  1049 +
  1050 +
  1051 + /* 诊断指导 */
  1052 + String diagnosis = "";
  1053 + if (org.apache.commons.lang.StringUtils.isNotEmpty(data.getDiagnosis())){
  1054 + List<String> temp = JsonUtil.toList(data.getDiagnosis(), String.class);
  1055 + if (CollectionUtils.isNotEmpty(temp)){
  1056 +
  1057 + StringBuilder sb = new StringBuilder();
  1058 +
  1059 + for (String sId : temp){
  1060 + sb.append(FunvCommonUtil.getBaseicConfigByid(sId, basicConfigService)).append(",");
  1061 + }
  1062 + if (sb.toString().endsWith(",")) {
  1063 + diagnosis = sb.substring(0, sb.length() - 1);
  1064 + }else {
  1065 + diagnosis = sb.toString();
  1066 + }
  1067 + }
  1068 + }else {
  1069 + diagnosis = "-";
  1070 + }
  1071 + map.put("diagnosis",diagnosis);
  1072 + map.put("treatOpinion",data.getTreatOpinion());
  1073 + map.put("dirOpinion",data.getDirOpinion());
  1074 +
  1075 + br.setErrorcode(ErrorCodeConstants.SUCCESS);
  1076 + br.setErrormsg("成功");
  1077 + br.setData(map);
1023 1078 return br;
1024 1079 }
  1080 +
  1081 +
  1082 +
1025 1083  
1026 1084  
1027 1085  
platform-operate-api/src/main/java/com/lyms/platform/operate/web/utils/UnitConstants.java View file @ 66765f8
... ... @@ -24,6 +24,7 @@
24 24 public static final String FEN = " 分";
25 25 public static final String FZ = " 分钟";
26 26 public static final String GE = " 个";
  27 + public static final String SUI = " 岁";
27 28  
28 29  
29 30 }