Commit 99dfd29a680abfca37b7289c9ddc563bfabbbe03

Authored by jiangjiazhi

Merge remote-tracking branch 'origin/master'

Showing 3 changed files

platform-operate-api/src/main/java/com/lyms/hospitalapi/qhdfy/QhdfyFmService.java View file @ 99dfd29
... ... @@ -44,11 +44,10 @@
44 44 @Autowired
45 45 private UsersService usersService;
46 46  
47   - public void fmTimerWork()
48   - {
  47 + public void fmTimerWork() {
49 48 SimpleDateFormat fmt = new SimpleDateFormat("yyyy-MM-dd HH:mm");
50 49 Date end = new Date();
51   - Date start = new Date(end.getTime()-1000*60*5);
  50 + Date start = new Date(end.getTime()-1000*60*60*24*6);
52 51 String startStr = fmt.format(start);
53 52 String endStr = fmt.format(end);
54 53 System.out.println("start="+startStr+"end="+endStr);
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/ViewFacade.java View file @ 99dfd29
... ... @@ -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());
92 94  
93 95  
... ... @@ -102,13 +104,24 @@
102 104  
103 105 /* 院内信息 */
104 106 map.put("lastMenses", DateUtil.getyyyy_MM_dd(data.getLastMenses()));
105   - //TODO 纠正末次月经
  107 + //纠正末次月经,取末次月经数据
  108 + map.put("correctionLastMenses", DateUtil.getyyyy_MM_dd(data.getLastMenses()));
106 109 map.put("dueDate", DateUtil.getyyyy_MM_dd(data.getDueDate()));
107 110 map.put("vcCardNo", data.getVcCardNo());
108 111 //TODO 条码
109   - //TODO 档案编号
  112 + //档案编号
  113 + map.put("fileCode", data.getFileCode());
110 114 map.put("mremark", data.getMremark());
111   - //TODO 服务类型
  115 + //服务类型
  116 + String serviceType = "";
  117 + if (data.getServiceType()!=null){
  118 + for (ServiceTypeEnums serviceTypeEnums:ServiceTypeEnums.values()){
  119 + if (data.getServiceType().equals(serviceTypeEnums.getId())){
  120 + serviceType = serviceTypeEnums.getName();
  121 + }
  122 + }
  123 + }
  124 + map.put("serviceType",serviceType );
112 125 map.put("serviceStatus", ServiceStatusEnums.getNameById(data.getServiceStatus()));
113 126  
114 127 br.setData(map);
... ... @@ -167,7 +180,7 @@
167 180 map.put("id",data.getId());
168 181 map.put("username",patients.getUsername());
169 182 map.put("birth", DateUtil.getyyyy_MM_dd(patients.getBirth()));
170   - map.put("age",DateUtil.getAge(patients.getBirth()));
  183 + map.put("age",UnitUtils.unitSplice(DateUtil.getAge(patients.getBirth()),UnitConstants.SUI));
171 184 map.put("phone",patients.getPhone());
172 185 map.put("fmWeek",patients.getFmWeek());
173 186 map.put("dueDate",DateUtil.getyyyy_MM_dd(patients.getDueDate()));
... ... @@ -986,7 +999,7 @@
986 999 map.put("id",data.getId());
987 1000 map.put("username",patients.getUsername());
988 1001 map.put("birth",DateUtil.getyyyy_MM_dd(patients.getBirth()));
989   - map.put("age",DateUtil.getAge(patients.getBirth()));
  1002 + map.put("age",UnitUtils.unitSplice(DateUtil.getAge(patients.getBirth()),UnitConstants.SUI));
990 1003 map.put("phone",patients.getPhone());
991 1004 map.put("fmWeek",patients.getFmWeek());
992 1005 map.put("dueDate",DateUtil.getyyyy_MM_dd(patients.getDueDate()));
993 1006  
994 1007  
995 1008  
996 1009  
... ... @@ -1016,12 +1029,68 @@
1016 1029 }
1017 1030  
1018 1031 map.put("hospitalId", hospitalId);
  1032 + map.put("nextCheckTime", DateUtil.getyyyy_MM_dd(data.getNextCheckTime()));
  1033 + map.put("healthStatus", data.getHealthStatus());
  1034 + map.put("psychology", data.getPsychology());
1019 1035  
1020   - String deliverDoctor = "";
  1036 + map.put("weight", UnitUtils.unitSplice(data.getWeight(),UnitConstants.KG));
  1037 + String ssy = "";
  1038 + String szy = "";
  1039 + Map<String, String> chBpMap = JsonUtil.getMap(data.getBp());
  1040 + if (MapUtils.isNotEmpty(chBpMap)) {
  1041 + ssy = chBpMap.get("ssy");
  1042 + szy = chBpMap.get("szy");
  1043 + }
  1044 + map.put("bp", UnitUtils.unitSplice(ssy + "/" + szy,UnitConstants.MMHG));
1021 1045  
  1046 + map.put("breast", data.getBreast());
  1047 + map.put("lochia", data.getLochia());
  1048 + map.put("vulva", data.getVulva());
  1049 + map.put("vagina", data.getVagina());
  1050 + map.put("cervixUteri", data.getCervixUteri());
  1051 + map.put("matrix", data.getMatrix());
  1052 + map.put("fujian", data.getFujian());
  1053 + map.put("wound", data.getWound());
  1054 + map.put("other", data.getOther());
1022 1055  
  1056 + map.put("basin", data.getBasin());
  1057 + map.put("traceElement", data.getTraceElement());
  1058 + map.put("boneDensity", data.getBoneDensity());
  1059 + map.put("ultrasonicExamination", data.getUltrasonicExamination());
  1060 +
  1061 +
  1062 + /* 诊断指导 */
  1063 + String diagnosis = "";
  1064 + if (org.apache.commons.lang.StringUtils.isNotEmpty(data.getDiagnosis())){
  1065 + List<String> temp = JsonUtil.toList(data.getDiagnosis(), String.class);
  1066 + if (CollectionUtils.isNotEmpty(temp)){
  1067 +
  1068 + StringBuilder sb = new StringBuilder();
  1069 +
  1070 + for (String sId : temp){
  1071 + sb.append(FunvCommonUtil.getBaseicConfigByid(sId, basicConfigService)).append(",");
  1072 + }
  1073 + if (sb.toString().endsWith(",")) {
  1074 + diagnosis = sb.substring(0, sb.length() - 1);
  1075 + }else {
  1076 + diagnosis = sb.toString();
  1077 + }
  1078 + }
  1079 + }else {
  1080 + diagnosis = "-";
  1081 + }
  1082 + map.put("diagnosis",diagnosis);
  1083 + map.put("treatOpinion",data.getTreatOpinion());
  1084 + map.put("dirOpinion",data.getDirOpinion());
  1085 +
  1086 + br.setErrorcode(ErrorCodeConstants.SUCCESS);
  1087 + br.setErrormsg("成功");
  1088 + br.setData(map);
1023 1089 return br;
1024 1090 }
  1091 +
  1092 +
  1093 +
1025 1094  
1026 1095  
1027 1096  
platform-operate-api/src/main/java/com/lyms/platform/operate/web/utils/UnitConstants.java View file @ 99dfd29
... ... @@ -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 }