Commit 8fcb294d4fef31e8c790fcc23836efd9132c8cb3
1 parent
5cf82478fd
Exists in
master
and in
6 other branches
听力诊断模块
Showing 6 changed files with 78 additions and 9 deletions
- .idea/artifacts/platform_sync_data_war_exploded.xml
- platform-biz-service/src/main/java/com/lyms/platform/permission/model/HighriskChangeHospitalQuery.java
- platform-biz-service/src/main/resources/mainOrm/master/HighriskChangeHospital.xml
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/FollowUpController.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/HearingDiagnoseController.java
- platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/HighriskChangeHospitalController.java
.idea/artifacts/platform_sync_data_war_exploded.xml
View file @
8fcb294
... | ... | @@ -13,6 +13,7 @@ |
13 | 13 | </element> |
14 | 14 | <element id="library" level="project" name="Maven: net.sourceforge.jexcelapi:jxl:2.6.12" /> |
15 | 15 | <element id="library" level="project" name="Maven: org.apache.commons:commons-lang3:3.4" /> |
16 | + <element id="library" level="project" name="Maven: com.oracle:ojdbc14:11.2.0.1.0" /> | |
16 | 17 | <element id="archive" name="platform-dal-1.0.1.jar"> |
17 | 18 | <element id="module-output" name="platform-dal" /> |
18 | 19 | </element> |
... | ... | @@ -106,7 +107,6 @@ |
106 | 107 | <element id="library" level="project" name="Maven: antlr:antlr:2.7.2" /> |
107 | 108 | <element id="library" level="project" name="Maven: org.apache.struts:struts-taglib:1.3.8" /> |
108 | 109 | <element id="library" level="project" name="Maven: org.apache.struts:struts-tiles:1.3.8" /> |
109 | - <element id="library" level="project" name="Maven: com.oracle:ojdbc14:11.2.0.1.0" /> | |
110 | 110 | <element id="library" level="project" name="Maven: commons-dbutils:commons-dbutils:1.6" /> |
111 | 111 | <element id="library" level="project" name="Maven: com.alibaba:fastjson:1.2.8" /> |
112 | 112 | </element> |
platform-biz-service/src/main/java/com/lyms/platform/permission/model/HighriskChangeHospitalQuery.java
View file @
8fcb294
... | ... | @@ -88,6 +88,16 @@ |
88 | 88 | * 听筛记录ID |
89 | 89 | */ |
90 | 90 | private String scrreenId; |
91 | + //听诊儿童档案集合 | |
92 | + private String[] babyIds; | |
93 | + | |
94 | + public String[] getBabyIds() { | |
95 | + return babyIds; | |
96 | + } | |
97 | + | |
98 | + public void setBabyIds(String[] babyIds) { | |
99 | + this.babyIds = babyIds; | |
100 | + } | |
91 | 101 | |
92 | 102 | public String getQueryNo() { |
93 | 103 | return queryNo; |
platform-biz-service/src/main/resources/mainOrm/master/HighriskChangeHospital.xml
View file @
8fcb294
... | ... | @@ -111,6 +111,14 @@ |
111 | 111 | <if test="targetType != null and targetType >= 0"> |
112 | 112 | and TARGET_TYPE = #{targetType,jdbcType=INTEGER} |
113 | 113 | </if> |
114 | + <if test="babyIds!=null"> | |
115 | + and TARGET_ID in ( | |
116 | + <foreach item="bId" collection="babyIds" separator=","> | |
117 | + #{bId} | |
118 | + </foreach> | |
119 | + ) | |
120 | + </if> | |
121 | + | |
114 | 122 | <if test="targetId != null and targetId != ''"> |
115 | 123 | and TARGET_ID = #{targetId,jdbcType=VARCHAR} |
116 | 124 | </if> |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/FollowUpController.java
View file @
8fcb294
1 | 1 | package com.lyms.platform.operate.web.controller; |
2 | 2 | |
3 | +import com.lyms.platform.biz.service.BabyBookbuildingService; | |
3 | 4 | import com.lyms.platform.biz.service.BabyService; |
4 | 5 | import com.lyms.platform.common.annotation.TokenRequired; |
5 | 6 | import com.lyms.platform.common.base.BaseController; |
... | ... | @@ -20,6 +21,8 @@ |
20 | 21 | import com.lyms.platform.permission.service.OrganizationService; |
21 | 22 | import com.lyms.platform.permission.service.UsersService; |
22 | 23 | import com.lyms.platform.pojo.BabyModel; |
24 | +import com.lyms.platform.query.BabyModelQuery; | |
25 | +import org.apache.commons.collections.CollectionUtils; | |
23 | 26 | import org.apache.commons.lang.StringUtils; |
24 | 27 | import org.springframework.beans.factory.annotation.Autowired; |
25 | 28 | import org.springframework.stereotype.Controller; |
... | ... | @@ -52,6 +55,8 @@ |
52 | 55 | private HighriskChangeHospitalService highchangeService; |
53 | 56 | @Autowired |
54 | 57 | private OrganizationService organizationService; |
58 | + @Autowired | |
59 | + private BabyBookbuildingService babyBookbuildingService; | |
55 | 60 | |
56 | 61 | |
57 | 62 | /** |
58 | 63 | |
... | ... | @@ -233,9 +238,21 @@ |
233 | 238 | query.setFollowUpEndTime(fur.getFollowUpEndTime()); |
234 | 239 | query.setFollowDoctorId(fur.getFollowDoctorId()); |
235 | 240 | |
241 | + //如果查询号不为空,根据查询号查询儿童档案表,获取儿童档案Id | |
236 | 242 | if (fur.getKeyWord() != null) {//关键字:姓名、联系方式、就诊卡 查询babyId |
237 | - //调用mysql表查询baby档案。 表还未设计 | |
238 | - // query.setBabyIds(); | |
243 | + BabyModelQuery babyQuery = new BabyModelQuery(); | |
244 | + babyQuery.setQueryNo(fur.getKeyWord()); | |
245 | + //查询建档记录 | |
246 | + List<BabyModel> models = babyBookbuildingService.queryBabyBuildByCond(babyQuery); | |
247 | + if(CollectionUtils.isNotEmpty(models)){ | |
248 | + List<String> babyIds = new ArrayList<>(); | |
249 | + for(BabyModel babyModel:models){ | |
250 | + babyIds.add(babyModel.getId()); | |
251 | + } | |
252 | + query.setBabyIds(babyIds.toArray(new String[babyIds.size()])); | |
253 | + }else{ | |
254 | + return new BaseResponse().setErrorcode(ErrorCodeConstants.SUCCESS).setErrormsg("没有找到数据"); | |
255 | + } | |
239 | 256 | } |
240 | 257 | |
241 | 258 | //确诊结果 |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/HearingDiagnoseController.java
View file @
8fcb294
1 | 1 | package com.lyms.platform.operate.web.controller; |
2 | 2 | |
3 | +import com.lyms.platform.biz.service.BabyBookbuildingService; | |
3 | 4 | import com.lyms.platform.biz.service.BabyService; |
4 | 5 | import com.lyms.platform.common.annotation.TokenRequired; |
5 | 6 | import com.lyms.platform.common.base.BaseController; |
... | ... | @@ -17,6 +18,7 @@ |
17 | 18 | import com.lyms.platform.permission.model.*; |
18 | 19 | import com.lyms.platform.permission.service.*; |
19 | 20 | import com.lyms.platform.pojo.BabyModel; |
21 | +import com.lyms.platform.query.BabyModelQuery; | |
20 | 22 | import org.apache.commons.collections.CollectionUtils; |
21 | 23 | import org.apache.commons.lang.StringUtils; |
22 | 24 | import org.springframework.beans.factory.annotation.Autowired; |
... | ... | @@ -54,6 +56,8 @@ |
54 | 56 | private BabyPatientExtendEarScreenService screenService; |
55 | 57 | @Autowired |
56 | 58 | private UsersService usersService; |
59 | + @Autowired | |
60 | + private BabyBookbuildingService babyBookbuildingService; | |
57 | 61 | |
58 | 62 | /** |
59 | 63 | * 根据儿童id获取最后一次确诊结果 |
... | ... | @@ -254,7 +258,6 @@ |
254 | 258 | |
255 | 259 | /** |
256 | 260 | * 获取听力诊断记录列表 |
257 | - * | |
258 | 261 | * @param hdReq 听力诊断记录对象 多条件查询 |
259 | 262 | * @param request |
260 | 263 | * @return |
... | ... | @@ -313,8 +316,19 @@ |
313 | 316 | BabyPatientExtendEarScreenQuery scrQuery = new BabyPatientExtendEarScreenQuery(); |
314 | 317 | //如果查询号不为空,根据查询号查询儿童档案表,获取儿童档案Id |
315 | 318 | if (hdReq.getKeyWord() != null) {//关键字:姓名、联系方式、就诊卡 查询babyId |
316 | - //调用mysql表查询baby档案。 表还未设计 | |
317 | - // scrQuery.setBabyIds(); | |
319 | + BabyModelQuery babyQuery = new BabyModelQuery(); | |
320 | + babyQuery.setQueryNo(hdReq.getKeyWord()); | |
321 | + //查询建档记录 | |
322 | + List<BabyModel> models = babyBookbuildingService.queryBabyBuildByCond(babyQuery); | |
323 | + if(CollectionUtils.isNotEmpty(models)){ | |
324 | + List<String> babyIds = new ArrayList<>(); | |
325 | + for(BabyModel babyModel:models){ | |
326 | + babyIds.add(babyModel.getId()); | |
327 | + } | |
328 | + scrQuery.setBabyIds(babyIds.toArray(new String[babyIds.size()])); | |
329 | + }else{ | |
330 | + return new BaseResponse().setErrorcode(ErrorCodeConstants.SUCCESS).setErrormsg("没有找到数据"); | |
331 | + } | |
318 | 332 | } |
319 | 333 | |
320 | 334 | scrQuery.setCheckHospitalIds((String[]) outOrgids.toArray(new String[outOrgids.size()])); |
platform-operate-api/src/main/java/com/lyms/platform/operate/web/controller/HighriskChangeHospitalController.java
View file @
8fcb294
1 | 1 | package com.lyms.platform.operate.web.controller; |
2 | 2 | |
3 | +import com.lyms.platform.biz.service.BabyBookbuildingService; | |
3 | 4 | import com.lyms.platform.biz.service.BabyService; |
4 | 5 | import com.lyms.platform.common.annotation.TokenRequired; |
5 | 6 | import com.lyms.platform.common.base.BaseController; |
... | ... | @@ -19,6 +20,8 @@ |
19 | 20 | import com.lyms.platform.permission.service.OrganizationService; |
20 | 21 | import com.lyms.platform.permission.service.UsersService; |
21 | 22 | import com.lyms.platform.pojo.BabyModel; |
23 | +import com.lyms.platform.query.BabyModelQuery; | |
24 | +import org.apache.commons.collections.CollectionUtils; | |
22 | 25 | import org.apache.commons.lang.StringUtils; |
23 | 26 | import org.eclipse.jetty.util.StringUtil; |
24 | 27 | import org.springframework.beans.factory.annotation.Autowired; |
... | ... | @@ -55,6 +58,8 @@ |
55 | 58 | private UsersService usersService; |
56 | 59 | @Autowired |
57 | 60 | private OrganizationService organizationService; |
61 | + @Autowired | |
62 | + private BabyBookbuildingService babyBookbuildingService; | |
58 | 63 | |
59 | 64 | |
60 | 65 | /** |
61 | 66 | |
... | ... | @@ -259,10 +264,7 @@ |
259 | 264 | if (loginState == null) { |
260 | 265 | return new BaseResponse().setErrorcode(ErrorCodeConstants.TOKEN_EXPIRE).setErrormsg("请重新登录"); |
261 | 266 | } |
262 | - //查询号 queryNo | |
263 | - //查询儿童表 和 母亲表 获取id | |
264 | 267 | |
265 | - | |
266 | 268 | //医院id |
267 | 269 | String hospitalId = autoMatchFacade.getHospitalId(loginState.getId()); |
268 | 270 | if (type != null && type == 1) {//转出 |
... | ... | @@ -273,6 +275,24 @@ |
273 | 275 | return new BaseResponse().setErrorcode(ErrorCodeConstants.PARAMETER_ERROR).setErrormsg("请传入查询类型"); |
274 | 276 | } |
275 | 277 | query.setNeed("1"); |
278 | + | |
279 | + //如果查询号不为空,根据查询号查询儿童档案表,获取儿童档案Id | |
280 | + if (query.getQueryNo() != null) {//关键字:姓名、联系方式、就诊卡 查询babyId | |
281 | + BabyModelQuery babyQuery = new BabyModelQuery(); | |
282 | + babyQuery.setQueryNo(query.getQueryNo()); | |
283 | + //查询建档记录 | |
284 | + List<BabyModel> models = babyBookbuildingService.queryBabyBuildByCond(babyQuery); | |
285 | + if(CollectionUtils.isNotEmpty(models)){ | |
286 | + List<String> babyIds = new ArrayList<>(); | |
287 | + for(BabyModel babyModel:models){ | |
288 | + babyIds.add(babyModel.getId()); | |
289 | + } | |
290 | + query.setBabyIds(babyIds.toArray(new String[babyIds.size()])); | |
291 | + }else{ | |
292 | + return new BaseResponse().setErrorcode(ErrorCodeConstants.SUCCESS).setErrormsg("没有找到数据"); | |
293 | + } | |
294 | + } | |
295 | + | |
276 | 296 | //医院id |
277 | 297 | List<HighriskChangeHospital> hchList = highriskChangeHospitalService.queryHighriskChangeHospital(query); |
278 | 298 |