Commit d9275f03ce26a003fa3b8ab5597c1ae3ebfbbb73
1 parent
70edb9a65c
Exists in
master
and in
1 other branch
增加科室值班护士回复/回访功能,前端3秒执行一次调用。聊天室状态(患者、医生分别查询)
Showing 2 changed files with 27 additions and 3 deletions
talkonlineweb/src/main/java/com/lyms/talkonlineweb/controller/ChatGroupController.java
View file @
d9275f0
... | ... | @@ -101,7 +101,7 @@ |
101 | 101 | //查询值班医生 |
102 | 102 | List<LymsDoctor> doctorAminList= lymsDoctorService.list(new QueryWrapper<LymsDoctor>() |
103 | 103 | .lambda().eq(LymsDoctor::getDpid, doctor.getDpid()) |
104 | - .eq(LymsDoctor::getAdminType, 1)); | |
104 | + .in(LymsDoctor::getAdminType, new int[]{1,2})); | |
105 | 105 | //科室值班医生注册环信 |
106 | 106 | for (LymsDoctor lymsDoctor : doctorAminList) { |
107 | 107 | if(StringUtil.isEmpty(lymsDoctor.getHxid())) { |
... | ... | @@ -395,6 +395,30 @@ |
395 | 395 | } |
396 | 396 | page.setRecords(list); |
397 | 397 | baseResponse.setObject(page); |
398 | + return baseResponse; | |
399 | + } | |
400 | + | |
401 | + /** | |
402 | + * 前端3秒执行一次调用。聊天室状态(患者、医生分别查询) | |
403 | + * @param request | |
404 | + * @return | |
405 | + */ | |
406 | + @GetMapping("getChatStat") | |
407 | + @TokenRequired | |
408 | + public BaseResponse getChatStat(Integer groupId){ | |
409 | + BaseResponse baseResponse =new BaseResponse(); | |
410 | + try { | |
411 | + final LymsChatgroup chatgroup = lymsChatgroupService.getOne(new QueryWrapper<LymsChatgroup>() | |
412 | + .lambda().eq(LymsChatgroup::getHxgroupid, groupId)); | |
413 | + final LymsTkrecord tkrecord = lymsTkrecordService.getOne(new QueryWrapper<LymsTkrecord>() | |
414 | + .lambda().eq(LymsTkrecord::getHxgroupid, groupId)); | |
415 | + Map<String,Object> map= new LinkedHashMap<>(); | |
416 | + map.put("groupStat",null==chatgroup?"":chatgroup.getStat()); | |
417 | + map.put("tkrecordStat",null==tkrecord?"":tkrecord.getStat()); | |
418 | + baseResponse.setObject(map); | |
419 | + } catch (Exception e) { | |
420 | + e.printStackTrace(); | |
421 | + } | |
398 | 422 | return baseResponse; |
399 | 423 | } |
400 | 424 |
talkonlineweb/src/main/java/com/lyms/talkonlineweb/controller/TkRecordController.java
View file @
d9275f0
... | ... | @@ -97,10 +97,10 @@ |
97 | 97 | lymsPatientService.updateById(patient); |
98 | 98 | } |
99 | 99 | } |
100 | - //查询值班医生 | |
100 | + //查询值班医生/值班护士 | |
101 | 101 | List<LymsDoctor> doctorAminList= lymsDoctorService.list(new QueryWrapper<LymsDoctor>() |
102 | 102 | .lambda().eq(LymsDoctor::getDpid, doctor.getDpid()) |
103 | - .eq(LymsDoctor::getAdminType, 1)); | |
103 | + .in(LymsDoctor::getAdminType, new int[]{1,2})); | |
104 | 104 | //科室值班医生注册环信 |
105 | 105 | for (LymsDoctor lymsDoctor : doctorAminList) { |
106 | 106 | if(StringUtil.isEmpty(lymsDoctor.getHxid())) { |