Commit 2947e6a869e92c01b02e17ee3c0143d4413be2fd
1 parent
1a3919466a
Exists in
master
and in
6 other branches
update
Showing 4 changed files with 533 additions and 1 deletions
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/AmniocentesisController.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/AmniocentesisFacade.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/ViewFacade.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/result/AmnioRecordResult.java
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/AmniocentesisController.java
View file @
2947e6a
... | ... | @@ -116,6 +116,8 @@ |
116 | 116 | } |
117 | 117 | |
118 | 118 | |
119 | + | |
120 | + | |
119 | 121 | /** |
120 | 122 | * 根据id查询数据 |
121 | 123 | * @param request |
... | ... | @@ -146,6 +148,39 @@ |
146 | 148 | return amniocentesisFacade.saveOrUpdateAmnioRecord(amnioRecordRequest, getUserId(request)); |
147 | 149 | |
148 | 150 | } |
151 | + | |
152 | + | |
153 | + /** | |
154 | + * 手术记录查看页面接口 | |
155 | + * @param request | |
156 | + * @param id | |
157 | + * @return | |
158 | + */ | |
159 | + @TokenRequired | |
160 | + @ResponseBody | |
161 | + @RequestMapping(value = "/queryAmnioRecordView", method = RequestMethod.GET) | |
162 | + public BaseResponse queryAmnioRecordView(HttpServletRequest request, | |
163 | + @RequestParam(required = true) String id) { | |
164 | + return amniocentesisFacade.queryAmnioRecordView(id, getUserId(request)); | |
165 | + | |
166 | + } | |
167 | + | |
168 | + | |
169 | + /** | |
170 | + * 根据id查询手术记录详情 | |
171 | + * @param request | |
172 | + * @param id | |
173 | + * @return | |
174 | + */ | |
175 | + @TokenRequired | |
176 | + @ResponseBody | |
177 | + @RequestMapping(value = "/queryAmnioRecordById", method = RequestMethod.GET) | |
178 | + public BaseResponse queryAmnioRecordById(HttpServletRequest request, | |
179 | + @RequestParam(required = true) String id) { | |
180 | + return amniocentesisFacade.queryAmnioRecordById(id, getUserId(request)); | |
181 | + | |
182 | + } | |
183 | + | |
149 | 184 | |
150 | 185 | |
151 | 186 | /** |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/AmniocentesisFacade.java
View file @
2947e6a
... | ... | @@ -15,15 +15,19 @@ |
15 | 15 | import com.lyms.platform.operate.web.request.AmnioResultRequest; |
16 | 16 | import com.lyms.platform.operate.web.request.AmniocentesisInfoRequest; |
17 | 17 | import com.lyms.platform.operate.web.request.AmniocentesisQueryRequest; |
18 | +import com.lyms.platform.operate.web.result.AmnioRecordResult; | |
18 | 19 | import com.lyms.platform.operate.web.result.AmnioResultResult; |
19 | 20 | import com.lyms.platform.operate.web.result.AmniocentesisInfo; |
20 | 21 | import com.lyms.platform.operate.web.result.AmniocentesisInfoView; |
21 | 22 | import com.lyms.platform.operate.web.utils.ResponseUtil; |
23 | +import com.lyms.platform.permission.model.Organization; | |
24 | +import com.lyms.platform.permission.service.OrganizationService; | |
22 | 25 | import com.lyms.platform.pojo.AmniocentesisInfoModel; |
23 | 26 | import com.lyms.platform.pojo.AmniocentesisRecordModel; |
24 | 27 | import com.lyms.platform.pojo.AmniocentesisResultModel; |
25 | 28 | import com.lyms.platform.pojo.Patients; |
26 | 29 | import com.lyms.platform.query.AmniocentesisInfoQuery; |
30 | +import com.lyms.platform.query.AmniocentesisRecordQuery; | |
27 | 31 | import com.lyms.platform.query.AmniocentesisResultQuery; |
28 | 32 | import com.lyms.platform.query.PatientsQuery; |
29 | 33 | import org.apache.commons.collections.CollectionUtils; |
... | ... | @@ -55,6 +59,9 @@ |
55 | 59 | private ViewFacade viewFacade; |
56 | 60 | |
57 | 61 | @Autowired |
62 | + private OrganizationService organizationService; | |
63 | + | |
64 | + @Autowired | |
58 | 65 | private PatientsService patientsService; |
59 | 66 | |
60 | 67 | public BaseResponse queryAmniocentesisInfo(String cardNo, String vcCardNo, Integer userId) { |
... | ... | @@ -385,7 +392,16 @@ |
385 | 392 | data.put("prodTime",model.getProdTime()); |
386 | 393 | data.put("tangDanger",model.getTangDanger() == null ? "" : "0".equals(model.getTangDanger()) ? |
387 | 394 | "低" : "1".equals(model.getTangDanger()) ? "中" : "高"); |
388 | - data.put("ReferralHospital",model.getReferralHospital()); | |
395 | + | |
396 | + String referralHospital = ""; | |
397 | + if (org.apache.commons.lang.StringUtils.isNotEmpty(model.getReferralHospital())) { | |
398 | + Organization organization = organizationService.getOrganization(Integer.parseInt(model.getReferralHospital())); | |
399 | + if (organization != null && organization.getYn() == YnEnums.YES.getId()) { | |
400 | + referralHospital = organization.getName(); | |
401 | + } | |
402 | + } | |
403 | + | |
404 | + data.put("ReferralHospital",referralHospital); | |
389 | 405 | data.put("operation",model.getOperation()); |
390 | 406 | data.put("applyDate",model.getApplyDate() == null ? "" : DateUtil.getyyyy_MM_dd(model.getApplyDate())); |
391 | 407 | data.put("orderDate",model.getOrderDate() == null ? "" : DateUtil.getyyyy_MM_dd(model.getOrderDate())); |
... | ... | @@ -428,6 +444,27 @@ |
428 | 444 | amniocentesisResultQuery.setId(id); |
429 | 445 | AmniocentesisResultModel resultModel = amniocentesisResultService.queryOne(amniocentesisResultQuery); |
430 | 446 | return new BaseObjectResponse().setData(resultModel).setErrorcode(ErrorCodeConstants.SUCCESS).setErrormsg(ErrorCodeConstants.SUCCESS_DESCRIPTION); |
447 | + } | |
448 | + | |
449 | + public BaseResponse queryAmnioRecordView(String id, Integer userId) { | |
450 | + AmniocentesisRecordQuery amniocentesisInfoQuery = new AmniocentesisRecordQuery(); | |
451 | + amniocentesisInfoQuery.setId(id); | |
452 | + AmniocentesisRecordModel model = amniocentesisRecordService.queryOne(amniocentesisInfoQuery); | |
453 | + AmnioRecordResult resultResult = null; | |
454 | + if (model != null) | |
455 | + { | |
456 | + resultResult = viewFacade.queryAmnioRecordView(model); | |
457 | + } | |
458 | + return new BaseObjectResponse().setData(resultResult).setErrorcode(ErrorCodeConstants.SUCCESS).setErrormsg(ErrorCodeConstants.SUCCESS_DESCRIPTION); | |
459 | + } | |
460 | + | |
461 | + public BaseResponse queryAmnioRecordById(String id, Integer userId) { | |
462 | + | |
463 | + AmniocentesisRecordQuery amniocentesisInfoQuery = new AmniocentesisRecordQuery(); | |
464 | + amniocentesisInfoQuery.setId(id); | |
465 | + AmniocentesisRecordModel model = amniocentesisRecordService.queryOne(amniocentesisInfoQuery); | |
466 | + return new BaseObjectResponse().setData(model).setErrorcode(ErrorCodeConstants.SUCCESS).setErrormsg(ErrorCodeConstants.SUCCESS_DESCRIPTION); | |
467 | + | |
431 | 468 | } |
432 | 469 | } |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/facade/ViewFacade.java
View file @
2947e6a
... | ... | @@ -216,6 +216,32 @@ |
216 | 216 | } |
217 | 217 | |
218 | 218 | |
219 | + public AmnioRecordResult queryAmnioRecordView(AmniocentesisRecordModel destModel) { | |
220 | + AmnioRecordResult data = new AmnioRecordResult(); | |
221 | + data.convertToResult(destModel); | |
222 | + String hospital = ""; | |
223 | + if (org.apache.commons.lang.StringUtils.isNotEmpty(destModel.getHospitalId())) { | |
224 | + Organization organization = organizationService.getOrganization(Integer.parseInt(destModel.getHospitalId())); | |
225 | + if (organization != null && organization.getYn() == YnEnums.YES.getId()) { | |
226 | + hospital = organization.getName(); | |
227 | + } | |
228 | + } | |
229 | + data.setHospitalName(hospital); | |
230 | + | |
231 | + //医生 | |
232 | + String user = ""; | |
233 | + if (destModel.getOperationUserId() != null) { | |
234 | + Users users = usersService.getUsers(destModel.getOperationUserId()); | |
235 | + if (users != null && users.getYn() == YnEnums.YES.getId()) { | |
236 | + user = users.getName(); | |
237 | + } | |
238 | + } | |
239 | + data.setOperationUser(user); | |
240 | + return null; | |
241 | + } | |
242 | + | |
243 | + | |
244 | + | |
219 | 245 | public AmnioResultResult getAmnioResultView(AmniocentesisResultModel destModel) { |
220 | 246 | AmnioResultResult data = new AmnioResultResult(); |
221 | 247 | data.convertToResult(destModel); |
... | ... | @@ -6458,6 +6484,7 @@ |
6458 | 6484 | } |
6459 | 6485 | return result; |
6460 | 6486 | } |
6487 | + | |
6461 | 6488 | |
6462 | 6489 | } |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/result/AmnioRecordResult.java
View file @
2947e6a
1 | +package com.lyms.platform.operate.web.result; | |
2 | + | |
3 | +import com.lyms.platform.common.base.IBasicResultConvert; | |
4 | +import com.lyms.platform.common.enums.AmnioResultEnums; | |
5 | +import com.lyms.platform.common.utils.DateUtil; | |
6 | +import com.lyms.platform.common.utils.StringUtils; | |
7 | +import com.lyms.platform.pojo.AmniocentesisRecordModel; | |
8 | +import com.lyms.platform.pojo.AmniocentesisResultModel; | |
9 | + | |
10 | +import java.util.Date; | |
11 | + | |
12 | + | |
13 | +/** | |
14 | + * Created by Administrator on 2019-10-14. | |
15 | + */ | |
16 | +public class AmnioRecordResult implements IBasicResultConvert<AmnioRecordResult, AmniocentesisRecordModel> { | |
17 | + | |
18 | + | |
19 | + //羊穿档案id 对象AmniocentesisInfoModel的主键 | |
20 | + private String amnioId; | |
21 | + | |
22 | + private String id; | |
23 | + | |
24 | + //主诉 | |
25 | + private String chiefComplaint; | |
26 | + | |
27 | + //病史 | |
28 | + private String medicalHistory; | |
29 | + | |
30 | + //既往毒害接触 | |
31 | + private String poisonous; | |
32 | + | |
33 | + //异常家族史 | |
34 | + private String familyHistory; | |
35 | + | |
36 | + //术前体温 | |
37 | + private String temperature; | |
38 | + | |
39 | + //高压 | |
40 | + private Integer hbloodPressure; | |
41 | + //低压 | |
42 | + private Integer lbloodPressure; | |
43 | + | |
44 | + | |
45 | + //心电图:血常规:血凝四项:肝肾功能:肝炎系列:梅毒艾滋病抗体 | |
46 | + //1未见异常 2异常 | |
47 | + | |
48 | + private String xdtContent; | |
49 | + | |
50 | + private String xcgContent; | |
51 | + | |
52 | + private String xnsxContent; | |
53 | + private String gsgnContent; | |
54 | + private String gyxlContent; | |
55 | + private String hivContent; | |
56 | + | |
57 | + //RH血型 1阳性 2 阴性 | |
58 | + private String hrContent; | |
59 | + | |
60 | + //B超 | |
61 | + private String bc; | |
62 | + | |
63 | + //羊水量 | |
64 | + private String bamnio; | |
65 | + | |
66 | + //双顶径 mm | |
67 | + private String sdj; | |
68 | + | |
69 | + //胎位 | |
70 | + private String tw; | |
71 | + | |
72 | + | |
73 | + //胎盘 | |
74 | + private String tp; | |
75 | + | |
76 | + //宫缩 | |
77 | + private String gs; | |
78 | + | |
79 | + //手术指征 | |
80 | + private String operation; | |
81 | + | |
82 | + //手术记录 | |
83 | + private String record; | |
84 | + | |
85 | + //穿刺部位 | |
86 | + private String position; | |
87 | + //羊穿次数 | |
88 | + private String amnioCount; | |
89 | + | |
90 | + //羊水量 | |
91 | + private String amnio; | |
92 | + | |
93 | + //羊水颜色 | |
94 | + private String amnioColor; | |
95 | + | |
96 | + //术后患者情况 | |
97 | + private String situation; | |
98 | + | |
99 | + | |
100 | + //术后处理 | |
101 | + private String deal; | |
102 | + | |
103 | + | |
104 | + //手术日期 | |
105 | + private String operationDate; | |
106 | + | |
107 | + //手术者id | |
108 | + private String operationUser; | |
109 | + | |
110 | + private String hospitalName; | |
111 | + | |
112 | + | |
113 | + @Override | |
114 | + public AmnioRecordResult convertToResult(AmniocentesisRecordModel destModel) { | |
115 | + setAmnioId(destModel.getAmnioId()); | |
116 | + setId(destModel.getId()); | |
117 | + setChiefComplaint(destModel.getChiefComplaint()); | |
118 | + setMedicalHistory(destModel.getMedicalHistory()); | |
119 | + setPoisonous(destModel.getPoisonous()); | |
120 | + setFamilyHistory(destModel.getFamilyHistory()); | |
121 | + setTemperature(destModel.getTemperature()); | |
122 | + setHbloodPressure(destModel.getHbloodPressure()); | |
123 | + setLbloodPressure(destModel.getLbloodPressure()); | |
124 | + | |
125 | + setXdtContent(getContent(destModel.getXdtStatus(), destModel.getXdtContent())); | |
126 | + setXcgContent(getContent(destModel.getXcgStatus(), destModel.getXcgContent())); | |
127 | + setXnsxContent(getContent(destModel.getXnsxStatus(), destModel.getXnsxContent())); | |
128 | + setGsgnContent(getContent(destModel.getGsgnStatus(), destModel.getGsgnContent())); | |
129 | + setGyxlContent(getContent(destModel.getGyxlStatus(), destModel.getGyxlContent())); | |
130 | + setHivContent(getContent(destModel.getHivStatus(), destModel.getHivContent())); | |
131 | + setHrContent(getContent(destModel.getHrStatus(), destModel.getHrContent())); | |
132 | + setBc(destModel.getBc()); | |
133 | + setBamnio(destModel.getBamnio()); | |
134 | + setSdj(destModel.getSdj()); | |
135 | + setTw(destModel.getTw()); | |
136 | + setTp(destModel.getTp()); | |
137 | + setGs(destModel.getGs()); | |
138 | + setOperation(destModel.getOperation()); | |
139 | + setRecord(destModel.getRecord()); | |
140 | + setPosition(destModel.getPosition()); | |
141 | + setAmnioCount(destModel.getAmnioCount()); | |
142 | + setAmnio(destModel.getAmnio()); | |
143 | + setAmnioColor(destModel.getAmnioColor()); | |
144 | + setSituation(destModel.getSituation()); | |
145 | + setDeal(destModel.getDeal()); | |
146 | + setOperationDate(DateUtil.getyyyy_MM_dd(destModel.getOperationDate())); | |
147 | + | |
148 | + return this; | |
149 | + } | |
150 | + | |
151 | + public String getContent(String status,String content) | |
152 | + { | |
153 | + if (StringUtils.isNotEmpty(status) && "1".equals(status)) | |
154 | + return "未见异常"; | |
155 | + if (StringUtils.isNotEmpty(status) && "2".equals(status)) | |
156 | + return content; | |
157 | + return ""; | |
158 | + } | |
159 | + | |
160 | + public String getHospitalName() { | |
161 | + return hospitalName; | |
162 | + } | |
163 | + | |
164 | + public void setHospitalName(String hospitalName) { | |
165 | + this.hospitalName = hospitalName; | |
166 | + } | |
167 | + | |
168 | + public String getAmnioId() { | |
169 | + return amnioId; | |
170 | + } | |
171 | + | |
172 | + public void setAmnioId(String amnioId) { | |
173 | + this.amnioId = amnioId; | |
174 | + } | |
175 | + | |
176 | + public String getId() { | |
177 | + return id; | |
178 | + } | |
179 | + | |
180 | + public void setId(String id) { | |
181 | + this.id = id; | |
182 | + } | |
183 | + | |
184 | + public String getChiefComplaint() { | |
185 | + return chiefComplaint; | |
186 | + } | |
187 | + | |
188 | + public void setChiefComplaint(String chiefComplaint) { | |
189 | + this.chiefComplaint = chiefComplaint; | |
190 | + } | |
191 | + | |
192 | + public String getMedicalHistory() { | |
193 | + return medicalHistory; | |
194 | + } | |
195 | + | |
196 | + public void setMedicalHistory(String medicalHistory) { | |
197 | + this.medicalHistory = medicalHistory; | |
198 | + } | |
199 | + | |
200 | + public String getPoisonous() { | |
201 | + return poisonous; | |
202 | + } | |
203 | + | |
204 | + public void setPoisonous(String poisonous) { | |
205 | + this.poisonous = poisonous; | |
206 | + } | |
207 | + | |
208 | + public String getFamilyHistory() { | |
209 | + return familyHistory; | |
210 | + } | |
211 | + | |
212 | + public void setFamilyHistory(String familyHistory) { | |
213 | + this.familyHistory = familyHistory; | |
214 | + } | |
215 | + | |
216 | + public String getTemperature() { | |
217 | + return temperature; | |
218 | + } | |
219 | + | |
220 | + public void setTemperature(String temperature) { | |
221 | + this.temperature = temperature; | |
222 | + } | |
223 | + | |
224 | + public Integer getHbloodPressure() { | |
225 | + return hbloodPressure; | |
226 | + } | |
227 | + | |
228 | + public void setHbloodPressure(Integer hbloodPressure) { | |
229 | + this.hbloodPressure = hbloodPressure; | |
230 | + } | |
231 | + | |
232 | + public Integer getLbloodPressure() { | |
233 | + return lbloodPressure; | |
234 | + } | |
235 | + | |
236 | + public void setLbloodPressure(Integer lbloodPressure) { | |
237 | + this.lbloodPressure = lbloodPressure; | |
238 | + } | |
239 | + | |
240 | + | |
241 | + public String getXdtContent() { | |
242 | + return xdtContent; | |
243 | + } | |
244 | + | |
245 | + public void setXdtContent(String xdtContent) { | |
246 | + this.xdtContent = xdtContent; | |
247 | + } | |
248 | + | |
249 | + | |
250 | + public String getXcgContent() { | |
251 | + return xcgContent; | |
252 | + } | |
253 | + | |
254 | + public void setXcgContent(String xcgContent) { | |
255 | + this.xcgContent = xcgContent; | |
256 | + } | |
257 | + | |
258 | + | |
259 | + public String getXnsxContent() { | |
260 | + return xnsxContent; | |
261 | + } | |
262 | + | |
263 | + public void setXnsxContent(String xnsxContent) { | |
264 | + this.xnsxContent = xnsxContent; | |
265 | + } | |
266 | + | |
267 | + | |
268 | + | |
269 | + public String getGsgnContent() { | |
270 | + return gsgnContent; | |
271 | + } | |
272 | + | |
273 | + public void setGsgnContent(String gsgnContent) { | |
274 | + this.gsgnContent = gsgnContent; | |
275 | + } | |
276 | + | |
277 | + | |
278 | + | |
279 | + public String getGyxlContent() { | |
280 | + return gyxlContent; | |
281 | + } | |
282 | + | |
283 | + public void setGyxlContent(String gyxlContent) { | |
284 | + this.gyxlContent = gyxlContent; | |
285 | + } | |
286 | + | |
287 | + | |
288 | + public String getHivContent() { | |
289 | + return hivContent; | |
290 | + } | |
291 | + | |
292 | + public void setHivContent(String hivContent) { | |
293 | + this.hivContent = hivContent; | |
294 | + } | |
295 | + | |
296 | + | |
297 | + | |
298 | + public String getHrContent() { | |
299 | + return hrContent; | |
300 | + } | |
301 | + | |
302 | + public void setHrContent(String hrContent) { | |
303 | + this.hrContent = hrContent; | |
304 | + } | |
305 | + | |
306 | + public String getBc() { | |
307 | + return bc; | |
308 | + } | |
309 | + | |
310 | + public void setBc(String bc) { | |
311 | + this.bc = bc; | |
312 | + } | |
313 | + | |
314 | + public String getBamnio() { | |
315 | + return bamnio; | |
316 | + } | |
317 | + | |
318 | + public void setBamnio(String bamnio) { | |
319 | + this.bamnio = bamnio; | |
320 | + } | |
321 | + | |
322 | + public String getSdj() { | |
323 | + return sdj; | |
324 | + } | |
325 | + | |
326 | + public void setSdj(String sdj) { | |
327 | + this.sdj = sdj; | |
328 | + } | |
329 | + | |
330 | + public String getTw() { | |
331 | + return tw; | |
332 | + } | |
333 | + | |
334 | + public void setTw(String tw) { | |
335 | + this.tw = tw; | |
336 | + } | |
337 | + | |
338 | + public String getTp() { | |
339 | + return tp; | |
340 | + } | |
341 | + | |
342 | + public void setTp(String tp) { | |
343 | + this.tp = tp; | |
344 | + } | |
345 | + | |
346 | + public String getGs() { | |
347 | + return gs; | |
348 | + } | |
349 | + | |
350 | + public void setGs(String gs) { | |
351 | + this.gs = gs; | |
352 | + } | |
353 | + | |
354 | + public String getOperation() { | |
355 | + return operation; | |
356 | + } | |
357 | + | |
358 | + public void setOperation(String operation) { | |
359 | + this.operation = operation; | |
360 | + } | |
361 | + | |
362 | + public String getRecord() { | |
363 | + return record; | |
364 | + } | |
365 | + | |
366 | + public void setRecord(String record) { | |
367 | + this.record = record; | |
368 | + } | |
369 | + | |
370 | + public String getPosition() { | |
371 | + return position; | |
372 | + } | |
373 | + | |
374 | + public void setPosition(String position) { | |
375 | + this.position = position; | |
376 | + } | |
377 | + | |
378 | + public String getAmnioCount() { | |
379 | + return amnioCount; | |
380 | + } | |
381 | + | |
382 | + public void setAmnioCount(String amnioCount) { | |
383 | + this.amnioCount = amnioCount; | |
384 | + } | |
385 | + | |
386 | + public String getAmnio() { | |
387 | + return amnio; | |
388 | + } | |
389 | + | |
390 | + public void setAmnio(String amnio) { | |
391 | + this.amnio = amnio; | |
392 | + } | |
393 | + | |
394 | + public String getAmnioColor() { | |
395 | + return amnioColor; | |
396 | + } | |
397 | + | |
398 | + public void setAmnioColor(String amnioColor) { | |
399 | + this.amnioColor = amnioColor; | |
400 | + } | |
401 | + | |
402 | + public String getSituation() { | |
403 | + return situation; | |
404 | + } | |
405 | + | |
406 | + public void setSituation(String situation) { | |
407 | + this.situation = situation; | |
408 | + } | |
409 | + | |
410 | + public String getDeal() { | |
411 | + return deal; | |
412 | + } | |
413 | + | |
414 | + public void setDeal(String deal) { | |
415 | + this.deal = deal; | |
416 | + } | |
417 | + | |
418 | + public String getOperationDate() { | |
419 | + return operationDate; | |
420 | + } | |
421 | + | |
422 | + public void setOperationDate(String operationDate) { | |
423 | + this.operationDate = operationDate; | |
424 | + } | |
425 | + | |
426 | + public String getOperationUser() { | |
427 | + return operationUser; | |
428 | + } | |
429 | + | |
430 | + public void setOperationUser(String operationUser) { | |
431 | + this.operationUser = operationUser; | |
432 | + } | |
433 | +} |