Merge remote-tracking branch 'origin/develop' into develop
This commit is contained in:
@@ -609,7 +609,7 @@ CREATE TABLE `con_helper` (
|
||||
`graduation_time` date NULL DEFAULT NULL COMMENT '毕业时间',
|
||||
`registration_time` datetime NULL DEFAULT NULL COMMENT '注册时间',
|
||||
`address` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '联系地址',
|
||||
`helper_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '小助手编号',
|
||||
`helper_id` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '全科医生编号',
|
||||
`flag` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '是否接受咨询1接受咨询2拒绝咨询',
|
||||
`work_time` varchar(100) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '参加工作时间',
|
||||
`practicing_experience` varchar(1000) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '执业经历',
|
||||
@@ -626,7 +626,7 @@ CREATE TABLE `con_helper` (
|
||||
`memo` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '备注',
|
||||
`org_code` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '所属部门',
|
||||
PRIMARY KEY (`id`) USING BTREE
|
||||
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = '小助手表' ROW_FORMAT = Dynamic;
|
||||
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_bin COMMENT = '全科医生表' ROW_FORMAT = Dynamic;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for con_helper_online
|
||||
|
||||
@@ -0,0 +1,36 @@
|
||||
/*
|
||||
Navicat Premium Data Transfer
|
||||
|
||||
Source Server : 蚁熊-阿里云
|
||||
Source Server Type : MySQL
|
||||
Source Server Version : 80404
|
||||
Source Host : localhost:3306
|
||||
Source Schema : health_consult
|
||||
|
||||
Target Server Type : MySQL
|
||||
Target Server Version : 80404
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 10/12/2025 15:53:17
|
||||
*/
|
||||
|
||||
SET NAMES utf8mb4;
|
||||
SET FOREIGN_KEY_CHECKS = 0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for im_msg_read_log
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `im_msg_read_log`;
|
||||
CREATE TABLE `im_msg_read_log` (
|
||||
`id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT 'id',
|
||||
`group_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '群组ID',
|
||||
`from_account` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '发送者账号',
|
||||
`to_account` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '接受者账号',
|
||||
`msg_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_general_ci NOT NULL COMMENT '消息ID(腾讯IM平台生成的消息ID)',
|
||||
`read_count` int NOT NULL COMMENT '读取次数(点击次数)',
|
||||
`read_time` datetime NOT NULL COMMENT '读取时间',
|
||||
PRIMARY KEY (`id`) USING BTREE,
|
||||
UNIQUE INDEX `group_id`(`group_id` ASC, `msg_id` ASC) USING BTREE
|
||||
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_general_ci ROW_FORMAT = Dynamic;
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
+1
-1
@@ -27,7 +27,7 @@ public class SessionFilter extends PageInfo<ConSession> {
|
||||
@Schema(description = "咨询方式 1图文聊天2音视频3电话4应急")
|
||||
private String contentType;
|
||||
|
||||
@Schema(description = "咨询类型 1员工咨询专家2员工咨询小助手3专家咨询小助手")
|
||||
@Schema(description = "咨询类型 1员工咨询专家2员工咨询全科医生3专家咨询全科医生")
|
||||
@NotBlank(message = "未知的查询类型")
|
||||
private String sessionType;
|
||||
|
||||
|
||||
+1
-1
@@ -8,7 +8,7 @@ import lombok.Data;
|
||||
@Data
|
||||
public class ConHelperDTO extends ConPage {
|
||||
|
||||
@Schema(title = "小助手姓名")
|
||||
@Schema(title = "全科医生姓名")
|
||||
private String userName;
|
||||
|
||||
@Schema(title = "状态")
|
||||
|
||||
+1
-1
@@ -40,7 +40,7 @@ public class ConSessionDTO extends ConPage {
|
||||
@Schema(title = "咨询结束日期")
|
||||
private String endDate;
|
||||
|
||||
@Schema(title = "菜单type(1为员工咨询专家 2用户咨询小助手 3专家咨询小助手)")
|
||||
@Schema(title = "菜单type(1为员工咨询专家 2用户咨询全科医生 3专家咨询全科医生)")
|
||||
private String sessionType;
|
||||
|
||||
@Schema(title = "二级单位id")
|
||||
|
||||
+3
-3
@@ -136,10 +136,10 @@ public class ConHelper extends ConPage implements Serializable {
|
||||
@Schema(title = "联系地址")
|
||||
private String address;
|
||||
/**
|
||||
* 小助手编号
|
||||
* 全科医生编号
|
||||
*/
|
||||
@Excel(name = "小助手编号", width = 15)
|
||||
@Schema(title = "小助手编号")
|
||||
@Excel(name = "全科医生编号", width = 15)
|
||||
@Schema(title = "全科医生编号")
|
||||
private String helperId;
|
||||
/**
|
||||
* 是否接受咨询1接受咨询2拒绝咨询
|
||||
|
||||
+7
-7
@@ -56,8 +56,8 @@ public class ConSession extends ConPage implements Serializable {
|
||||
/**
|
||||
* 接受者id
|
||||
*/
|
||||
@Excel(name = "接受者id(小助手id)", width = 15)
|
||||
@Schema(title = "接受者id(小助手id)")
|
||||
@Excel(name = "接受者id(全科医生id)", width = 15)
|
||||
@Schema(title = "接受者id(全科医生id)")
|
||||
private String toAccount;
|
||||
/**
|
||||
* 会话结束时间
|
||||
@@ -82,10 +82,10 @@ public class ConSession extends ConPage implements Serializable {
|
||||
@Schema(title = "预约时间")
|
||||
private Date reservationTime;
|
||||
/**
|
||||
* 1专家2小助手
|
||||
* 1专家2全科医生
|
||||
*/
|
||||
@Excel(name = "1员工咨询专家2员工咨询小助手3专家咨询小助手", width = 15)
|
||||
@Schema(title = "1员工咨询专家2员工咨询小助手3专家咨询小助手")
|
||||
@Excel(name = "1员工咨询专家2员工咨询全科医生3专家咨询全科医生", width = 15)
|
||||
@Schema(title = "1员工咨询专家2员工咨询全科医生3专家咨询全科医生")
|
||||
@Dict(dicCode = "con_type")
|
||||
private String sessionType;
|
||||
/**
|
||||
@@ -103,8 +103,8 @@ public class ConSession extends ConPage implements Serializable {
|
||||
/**
|
||||
* 接受者姓名
|
||||
*/
|
||||
@Excel(name = "接受者姓名(小助手姓名)", width = 15)
|
||||
@Schema(title = "接受者姓名(小助手姓名)")
|
||||
@Excel(name = "接受者姓名(全科医生姓名)", width = 15)
|
||||
@Schema(title = "接受者姓名(全科医生姓名)")
|
||||
private String toName;
|
||||
/**
|
||||
* im聊天信息id
|
||||
|
||||
+65
@@ -0,0 +1,65 @@
|
||||
package com.renkang.consultation.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
import lombok.EqualsAndHashCode;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @Description: Im消息已读日志 , 目前用于新疆项目中医生名片点击次数限制 且此表中暂时只存储了医生名片类型的消息
|
||||
* @Author: feng
|
||||
* @Date: 2025-12-10
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Data
|
||||
@TableName("im_msg_read_log")
|
||||
@EqualsAndHashCode(callSuper = false)
|
||||
@Schema(title = "Im消息已读日志", description = "Im消息已读日志")
|
||||
public class ImMsgReadLog implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
/**
|
||||
* id
|
||||
*/
|
||||
@TableId(type = IdType.ASSIGN_ID)
|
||||
@Schema(title = "id")
|
||||
private String id;
|
||||
/**
|
||||
* 群组ID
|
||||
*/
|
||||
@Schema(title = "群组ID")
|
||||
private String groupId;
|
||||
/**
|
||||
* 发送者账号
|
||||
*/
|
||||
@Schema(title = "发送者账号")
|
||||
private String fromAccount;
|
||||
/**
|
||||
* 接受者账号(消息已读人员账号)
|
||||
*/
|
||||
@Schema(title = "接受者账号")
|
||||
private String toAccount;
|
||||
/**
|
||||
* 消息ID (腾讯IM平台生成的消息ID 并非im_msg_record_all表的ID)
|
||||
*/
|
||||
@Schema(title = "消息ID(腾讯IM平台生成的消息ID)")
|
||||
private String msgId;
|
||||
/**
|
||||
* 读取次数(点击次数)
|
||||
*/
|
||||
@Schema(title = "读取次数(点击次数)")
|
||||
private Integer readCount;
|
||||
/**
|
||||
* 发送时间
|
||||
*/
|
||||
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@Schema(title = "读取时间")
|
||||
private Date readTime;
|
||||
}
|
||||
+2
-2
@@ -39,9 +39,9 @@ public class UserToHelpExportVO {
|
||||
private String userDeptName;
|
||||
|
||||
/**
|
||||
* 小助手姓名
|
||||
* 全科医生姓名
|
||||
*/
|
||||
@Excel(name = "小助手", width = 15,orderNum = "6")
|
||||
@Excel(name = "全科医生", width = 15,orderNum = "6")
|
||||
private String doctorName;
|
||||
|
||||
/**
|
||||
|
||||
+4
-4
@@ -8,14 +8,14 @@ import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
@Schema(title = "小助手信息小助手对象")
|
||||
@Schema(title = "全科医生信息对象")
|
||||
@Data
|
||||
public class ConHelperHelperVO {
|
||||
|
||||
@Schema(title = "小助手id")
|
||||
@Schema(title = "全科医生id")
|
||||
private String id;
|
||||
|
||||
@Schema(title = "小助手姓名")
|
||||
@Schema(title = "全科医生姓名")
|
||||
private String helperName;
|
||||
|
||||
@Schema(title = "部门id")
|
||||
@@ -69,7 +69,7 @@ public class ConHelperHelperVO {
|
||||
@Schema(title = "是否接受咨询1接受咨询2拒绝咨询")
|
||||
private String flag;
|
||||
|
||||
@Schema(title = "小助手编号")
|
||||
@Schema(title = "全科医生编号")
|
||||
private String helperId;
|
||||
|
||||
@Schema(title = "参加工作时间")
|
||||
|
||||
+1
-1
@@ -10,7 +10,7 @@ import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
@Schema(title = "小助手信息用户对象")
|
||||
@Schema(title = "全科医生信息用户对象")
|
||||
@Data
|
||||
public class ConHelperUserVO {
|
||||
|
||||
|
||||
+2
-2
@@ -12,9 +12,9 @@ public class ConHelperVO {
|
||||
@Schema(title = "id")
|
||||
private String id;
|
||||
|
||||
@Schema(title = "小助手姓名")
|
||||
@Schema(title = "全科医生姓名")
|
||||
private String userName;
|
||||
@Schema(title = "小助手账号")
|
||||
@Schema(title = "全科医生账号")
|
||||
private String userAccount;
|
||||
|
||||
@Schema(title = "头像")
|
||||
|
||||
+3
-3
@@ -70,12 +70,12 @@ public class ConSessionHelperVO {
|
||||
@Schema(title = "历史咨询专用")
|
||||
private String name;
|
||||
|
||||
@Schema(title = "小助手id")
|
||||
@Schema(title = "全科医生id")
|
||||
private String helperId;
|
||||
|
||||
@Schema(title = "小助手姓名")
|
||||
@Schema(title = "全科医生姓名")
|
||||
private String helperName;
|
||||
|
||||
@Schema(title = "1员工咨询专家2员工咨询小助手3专家咨询小助手")
|
||||
@Schema(title = "1员工咨询专家2员工咨询全科医生3专家咨询全科医生")
|
||||
private String sessionType;
|
||||
}
|
||||
|
||||
+35
@@ -0,0 +1,35 @@
|
||||
package com.renkang.consultation.vo;
|
||||
|
||||
import io.swagger.v3.oas.annotations.media.Schema;
|
||||
import lombok.Data;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
@Data
|
||||
@Schema(title = "Im消息已读日志vo", description = "Im消息已读日志vo")
|
||||
public class ImMsgReadLogVO {
|
||||
/**
|
||||
* 群组ID
|
||||
*/
|
||||
@Schema(title = "群组ID")
|
||||
@NotNull(message = "缺少必填参数:groupid")
|
||||
private String groupId;
|
||||
/**
|
||||
* 发送者账号
|
||||
*/
|
||||
@Schema(title = "发送者账号")
|
||||
@NotNull(message = "缺少必填参数:fromAccount")
|
||||
private String fromAccount;
|
||||
/**
|
||||
* 接受者账号(消息已读人员账号)
|
||||
*/
|
||||
@Schema(title = "接受者账号")
|
||||
@NotNull(message = "缺少必填参数:toAccount")
|
||||
private String toAccount;
|
||||
/**
|
||||
* 消息ID (腾讯IM平台生成的消息ID 并非im_msg_record_all表的ID)
|
||||
*/
|
||||
@Schema(title = "消息ID(腾讯IM平台生成的消息ID)")
|
||||
@NotNull(message = "缺少必填参数:msgId")
|
||||
private String msgId;
|
||||
}
|
||||
+5
-5
@@ -19,7 +19,7 @@ public class ConHelperApiController {
|
||||
@Autowired
|
||||
private ConHelperApiService conHelperApiService;
|
||||
|
||||
@Operation(summary = "查询小助手", description = "查询问题列表")
|
||||
@Operation(summary = "查询全科医生", description = "查询问题列表")
|
||||
@GetMapping("/selectHelperInfo")
|
||||
public Result<String> selectHelperInfo() {
|
||||
|
||||
@@ -27,11 +27,11 @@ public class ConHelperApiController {
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询小助手
|
||||
* 查询全科医生
|
||||
* @param helpId
|
||||
* @return
|
||||
*/
|
||||
@Operation(summary = "查询小助手", description = "查询小助手")
|
||||
@Operation(summary = "查询全科医生", description = "查询全科医生")
|
||||
@GetMapping("/selectHelperInfoDesc")
|
||||
public Result<ConHelperCustomUserVO> selectHelperInfoDesc(@RequestParam(value = "helpId") String helpId) {
|
||||
|
||||
@@ -39,11 +39,11 @@ public class ConHelperApiController {
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询是否小助手
|
||||
* 查询是否全科医生
|
||||
* @param helpId
|
||||
* @return
|
||||
*/
|
||||
@Operation(summary = "查询是否小助手", description = "查询是否小助手")
|
||||
@Operation(summary = "查询是否全科医生", description = "查询是否全科医生")
|
||||
@GetMapping("/selectTfHelper")
|
||||
public Result<Boolean> selectTfHelper(@RequestParam(value = "helpId") String helpId) {
|
||||
|
||||
|
||||
+10
-10
@@ -43,11 +43,11 @@ public class ConSessionApiController {
|
||||
}
|
||||
|
||||
/**
|
||||
* 专家咨询小助手
|
||||
* 专家咨询全科医生
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Operation(summary = "专家咨询小助手", description = "专家咨询小助手")
|
||||
@Operation(summary = "专家咨询全科医生", description = "专家咨询全科医生")
|
||||
@GetMapping("/insertProfessorAndHelperSession")
|
||||
public Result<Map<String, Object>> insertProfessorAndHelperSession() {
|
||||
|
||||
@@ -55,12 +55,12 @@ public class ConSessionApiController {
|
||||
}
|
||||
|
||||
/**
|
||||
* 专家咨询小助手 展示小助手Id
|
||||
* 专家咨询全科医生 展示全科医生Id
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
|
||||
@Operation(summary = "专家咨询小助手 展示", description = "专家咨询小助手")
|
||||
@Operation(summary = "专家咨询全科医生 展示", description = "专家咨询全科医生")
|
||||
@GetMapping("/insertProfessorAndHelperSessionShow")
|
||||
public Result<String> insertProfessorAndHelperSessionShow() {
|
||||
|
||||
@@ -68,11 +68,11 @@ public class ConSessionApiController {
|
||||
}
|
||||
|
||||
/**
|
||||
* 用户咨询小助手
|
||||
* 用户咨询全科医生
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Operation(summary = "用户咨询小助手", description = "用户咨询小助手")
|
||||
@Operation(summary = "用户咨询全科医生", description = "用户咨询全科医生")
|
||||
@GetMapping("/insertUserAndHelperSession")
|
||||
public Result<Map<String, Object>> insertUserAndHelperSession() {
|
||||
|
||||
@@ -310,14 +310,14 @@ public class ConSessionApiController {
|
||||
}
|
||||
|
||||
|
||||
@Operation(summary = "小助手咨询开始", description = "小助手咨询开始")
|
||||
@Operation(summary = "全科医生咨询开始", description = "全科医生咨询开始")
|
||||
@GetMapping("/startPictureTextSessionHelper")
|
||||
public Result<String> startPictureTextSessionHelper(@RequestParam(value = "fromAccount") String fromAccount, @RequestParam(value = "toAccount") String toAccount) {
|
||||
return conSessionApiService.startPictureTextSessionHelper(fromAccount, toAccount);
|
||||
}
|
||||
|
||||
|
||||
@Operation(summary = "专家咨询小助手 和 用户咨询小助手 超过四个小时结束", description = "专家咨询小助手 和 用户咨询小助手 超过四个小时结束")
|
||||
@Operation(summary = "专家咨询全科医生 和 用户咨询全科医生 超过四个小时结束", description = "专家咨询全科医生 和 用户咨询全科医生 超过四个小时结束")
|
||||
@GetMapping("/endUserAndProfessiorHelper")
|
||||
public Result<String> endUserAndProfessiorHelper(@RequestParam(value = "expireHour") String expireHour) {
|
||||
return conSessionApiService.endUserAndProfessiorHelper(expireHour);
|
||||
@@ -450,7 +450,7 @@ public class ConSessionApiController {
|
||||
* @param pageSize
|
||||
* @return
|
||||
*/
|
||||
@Operation(summary = "查询咨询列表 小助手", description = "查询咨询列表 小助手")
|
||||
@Operation(summary = "查询咨询列表 全科医生", description = "查询咨询列表 全科医生")
|
||||
@GetMapping("/selectSessionListByDoctorIdHelper")
|
||||
public Result<List<ConSessionDO>> selectSessionListByDoctorIdHelper(@RequestParam(value = "pageNo", defaultValue = "1") int pageNo,
|
||||
@RequestParam(value = "pageSize", defaultValue = "10") int pageSize) {
|
||||
@@ -473,7 +473,7 @@ public class ConSessionApiController {
|
||||
* 青海使用用户咨询 全科专家
|
||||
* @return
|
||||
*/
|
||||
@Operation(summary = "用户咨询小助手 新的", description = "用户咨询小助手 新的")
|
||||
@Operation(summary = "用户咨询全科医生 新的", description = "用户咨询全科医生 新的")
|
||||
@GetMapping("/insertUserAndHelperSessionNew")
|
||||
public Result<Map<String, Object>> insertUserAndHelperSessionNew() {
|
||||
|
||||
|
||||
+2
-2
@@ -47,7 +47,7 @@ public class ConHelperApiServiceImpl implements ConHelperApiService {
|
||||
|
||||
String helperUser = this.selectHelperUser();
|
||||
if (StringUtils.isEmpty(helperUser)) {
|
||||
return Result.error("暂无小助手在线");
|
||||
return Result.error("暂无全科医生在线");
|
||||
}
|
||||
|
||||
return Result.ok(helperUser);
|
||||
@@ -58,7 +58,7 @@ public class ConHelperApiServiceImpl implements ConHelperApiService {
|
||||
ConHelper conHelper = conHelperMapper.selectConHelperbyId(helpId);
|
||||
|
||||
if(conHelper == null){
|
||||
return Result.error("小助手不存在");
|
||||
return Result.error("全科医生不存在");
|
||||
}
|
||||
conHelper.setUserName("全科医生");
|
||||
ConHelperCustomUserVO conHelperCustomUserVO = new ConHelperCustomUserVO();
|
||||
|
||||
+6
-6
@@ -260,12 +260,12 @@ public class ConSessionApiServiceImpl implements ConSessionApiService {
|
||||
String helpUser = conHelperApiServiceImpl.selectHelperUser();
|
||||
|
||||
if (StrUtil.isEmpty(helpUser)) {
|
||||
return Result.error("小助手不存在,无法预约");
|
||||
return Result.error("全科医生不存在,无法预约");
|
||||
}
|
||||
|
||||
ConHelper conHelper = conHelperMapper.selectById(helpUser);
|
||||
if (conHelper == null) {
|
||||
return Result.error("小助手不存在,无法预约");
|
||||
return Result.error("全科医生不存在,无法预约");
|
||||
|
||||
}
|
||||
|
||||
@@ -394,7 +394,7 @@ public class ConSessionApiServiceImpl implements ConSessionApiService {
|
||||
}
|
||||
//如果是用户咨询全科医生 并且是青海
|
||||
if (StrUtil.equals(conSession.getSessionType(), "2")) {
|
||||
//如果用户发验 并且小助手在休息时间 那么自动发送消息
|
||||
//如果用户发验 并且全科医生在休息时间 那么自动发送消息
|
||||
this.helperSendMessage(conSession.getImId(), fromAccount, conSession.getToAccount());
|
||||
}
|
||||
|
||||
@@ -1275,7 +1275,7 @@ public class ConSessionApiServiceImpl implements ConSessionApiService {
|
||||
|
||||
String helper = conHelperApiServiceImpl.selectHelperUser();
|
||||
if (StrUtil.isEmpty(helper)) {
|
||||
return Result.error("暂无小助手可以服务");
|
||||
return Result.error("暂无全科医生可以服务");
|
||||
}
|
||||
|
||||
List<String> yesIds = new ArrayList<>();
|
||||
@@ -1367,12 +1367,12 @@ public class ConSessionApiServiceImpl implements ConSessionApiService {
|
||||
|
||||
String helper = conHelperApiServiceImpl.selectHelperUser();
|
||||
if (StrUtil.isEmpty(helper)) {
|
||||
return Result.error("暂无小助手可以服务");
|
||||
return Result.error("暂无全科医生可以服务");
|
||||
}
|
||||
|
||||
ConHelper conHelper = conHelperMapper.selectById(helper);
|
||||
if (conHelper == null) {
|
||||
return Result.error("暂无小助手可以服务");
|
||||
return Result.error("暂无全科医生可以服务");
|
||||
}
|
||||
|
||||
List<String> yesIds = new ArrayList<>();
|
||||
|
||||
+2
-2
@@ -334,7 +334,7 @@ public class AsyncExportService {
|
||||
ConSession conSession = new ConSession();
|
||||
BeanUtils.copyProperties(dto, conSession);
|
||||
LambdaQueryWrapper<ConSession> sessionWrapper = new LambdaQueryWrapper<>();
|
||||
// 只查询员工咨询小助手的数据
|
||||
// 只查询员工咨询全科医生的数据
|
||||
sessionWrapper.eq(ConSession::getSessionType, "2");
|
||||
sessionWrapper.and(
|
||||
p -> p.eq(ConSession::getTfReply, TF_REPLY_TRUE)
|
||||
@@ -415,7 +415,7 @@ public class AsyncExportService {
|
||||
if (CollUtil.isNotEmpty(conSessionList)) {
|
||||
// 取出用户的id
|
||||
List<String> userIdList = conSessionList.stream().map(ConSession::getFromAccount).distinct().collect(Collectors.toList());
|
||||
// 取出小助手的id
|
||||
// 取出全科医生的id
|
||||
List<String> helpIdList = conSessionList.stream().map(ConSession::getToAccount).distinct().collect(Collectors.toList());
|
||||
|
||||
// 查询用户信息
|
||||
|
||||
+13
-13
@@ -38,7 +38,7 @@ import java.util.List;
|
||||
* @Date: 2023-05-24
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Tag(name = "consult/健康咨询/小助手管理")
|
||||
@Tag(name = "consult/健康咨询/全科医生管理")
|
||||
@RestController
|
||||
@RequestMapping("/conHelper")
|
||||
@Slf4j
|
||||
@@ -68,10 +68,10 @@ public class ConHelperController extends JeecgController<ConHelper, IConHelperSe
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param conHelperExAndUser 小助手信息及用户基础信息
|
||||
* @param conHelperExAndUser 全科医生信息及用户基础信息
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "添加小助手信息及用户基础信息")
|
||||
@AutoLog(value = "添加全科医生信息及用户基础信息")
|
||||
@Operation(summary = "添加", description = "添加")
|
||||
@RequiresPermissions("consultation:con_helper:add")
|
||||
@PostMapping(value = "/add")
|
||||
@@ -84,10 +84,10 @@ public class ConHelperController extends JeecgController<ConHelper, IConHelperSe
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param conHelperExAndUser 小助手信息及用户基础信息
|
||||
* @param conHelperExAndUser 全科医生信息及用户基础信息
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "编辑小助手信息及用户基础信息")
|
||||
@AutoLog(value = "编辑全科医生信息及用户基础信息")
|
||||
@Operation(summary = "编辑", description = "编辑")
|
||||
@RequiresPermissions("consultation:con_helper:edit")
|
||||
@RequestMapping(value = "/edit", method = {RequestMethod.PUT, RequestMethod.POST})
|
||||
@@ -102,7 +102,7 @@ public class ConHelperController extends JeecgController<ConHelper, IConHelperSe
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "通过id删除小助手信息")
|
||||
@AutoLog(value = "通过id删除全科医生信息")
|
||||
@Operation(summary = "通过id删除", description = "通过id删除")
|
||||
@RequiresPermissions("consultation:con_helper:delete")
|
||||
@DeleteMapping(value = "/delete")
|
||||
@@ -120,7 +120,7 @@ public class ConHelperController extends JeecgController<ConHelper, IConHelperSe
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "批量删除小助手信息")
|
||||
@AutoLog(value = "批量删除全科医生信息")
|
||||
@Operation(summary = "批量删除", description = "批量删除")
|
||||
@RequiresPermissions("consultation:con_helper:deleteBatch")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
@@ -139,7 +139,7 @@ public class ConHelperController extends JeecgController<ConHelper, IConHelperSe
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id 小助手id
|
||||
* @param id 全科医生id
|
||||
* @return
|
||||
*/
|
||||
@Operation(summary = "通过id查询", description = "通过id查询")
|
||||
@@ -161,7 +161,7 @@ public class ConHelperController extends JeecgController<ConHelper, IConHelperSe
|
||||
@RequiresPermissions("consultation:con_helper:exportXls")
|
||||
@RequestMapping(value = "/exportXls")
|
||||
@Operation(summary = "导出")
|
||||
@AutoLog(value = "导出小助手信息")
|
||||
@AutoLog(value = "导出全科医生信息")
|
||||
public ModelAndView exportXls(HttpServletRequest request, ConHelper conHelper) {
|
||||
return super.exportXls(request, conHelper, ConHelper.class, "con_helper");
|
||||
}
|
||||
@@ -175,25 +175,25 @@ public class ConHelperController extends JeecgController<ConHelper, IConHelperSe
|
||||
*/
|
||||
@RequiresPermissions("consultation:con_helper:importExcel")
|
||||
@Operation(summary = "导入")
|
||||
@AutoLog(value = "导入小助手信息")
|
||||
@AutoLog(value = "导入全科医生信息")
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, ConHelper.class);
|
||||
}
|
||||
|
||||
/**
|
||||
* 小助手排班人员选择
|
||||
* 全科医生排班人员选择
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@RequestMapping(value = "/getHelperIds")
|
||||
@Operation(summary = "小助手排班人员选择")
|
||||
@Operation(summary = "全科医生排班人员选择")
|
||||
public Result<List<ConHelperSelectVO>> getHelperIds() {
|
||||
return Result.OK(conHelperService.getHelperIds());
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取当前可用小助手
|
||||
* 获取当前可用全科医生
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
|
||||
+1
-1
@@ -27,7 +27,7 @@ import java.util.Arrays;
|
||||
* @Date: 2023-05-23
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Tag(name = "consult/健康咨询/小助手管理/班次")
|
||||
@Tag(name = "consult/健康咨询/全科医生管理/班次")
|
||||
@RestController
|
||||
@RequestMapping("/conHelperOnline")
|
||||
@Slf4j
|
||||
|
||||
+13
-13
@@ -27,7 +27,7 @@ import java.util.List;
|
||||
* @Date: 2023-05-23
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Tag(name = "consult/健康咨询/小助手管理/全部排班")
|
||||
@Tag(name = "consult/健康咨询/全科医生管理/全部排班")
|
||||
@RestController
|
||||
@RequestMapping("/conHelperScheduling")
|
||||
@Slf4j
|
||||
@@ -36,24 +36,24 @@ public class ConHelperSchedulingController extends JeecgController<ConHelperSche
|
||||
private IConHelperSchedulingService conHelperSchedulingService;
|
||||
|
||||
/**
|
||||
* 小助手排班列表
|
||||
* 全科医生排班列表
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Operation(summary = "小助手排班列表", description = "小助手排班列表")
|
||||
@Operation(summary = "全科医生排班列表", description = "全科医生排班列表")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<List<ConHelperSchedulingCustomVO>> list() {
|
||||
return Result.OK(conHelperSchedulingService.listCustom());
|
||||
}
|
||||
|
||||
/**
|
||||
* 小助手修改排班
|
||||
* 全科医生修改排班
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@Operation(summary = "小助手修改排班", description = "小助手修改排班")
|
||||
@Operation(summary = "全科医生修改排班", description = "全科医生修改排班")
|
||||
@PostMapping("/updateHelperCustom")
|
||||
@AutoLog(value = "小助手修改排班")
|
||||
@AutoLog(value = "全科医生修改排班")
|
||||
public Result<List<ConHelperSchedulingCustomVO>> updateHelperCustom(@RequestBody @Validated ConHelperCustomDTO dto) {
|
||||
boolean result = conHelperSchedulingService.updateScheduleDefault(dto);
|
||||
if (result) {
|
||||
@@ -68,7 +68,7 @@ public class ConHelperSchedulingController extends JeecgController<ConHelperSche
|
||||
* @param conHelperScheduling
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "添加小助手排班")
|
||||
@AutoLog(value = "添加全科医生排班")
|
||||
@Operation(summary = "con_helper_scheduling-添加", description = "con_helper_scheduling-添加")
|
||||
@RequiresPermissions("consultation:con_helper_scheduling:add")
|
||||
@PostMapping(value = "/add")
|
||||
@@ -83,7 +83,7 @@ public class ConHelperSchedulingController extends JeecgController<ConHelperSche
|
||||
* @param conHelperScheduling
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "编辑小助手排班")
|
||||
@AutoLog(value = "编辑全科医生排班")
|
||||
@Operation(summary = "con_helper_scheduling-编辑", description = "con_helper_scheduling-编辑")
|
||||
@RequiresPermissions("consultation:con_helper_scheduling:edit")
|
||||
@RequestMapping(value = "/edit", method = {RequestMethod.PUT, RequestMethod.POST})
|
||||
@@ -98,7 +98,7 @@ public class ConHelperSchedulingController extends JeecgController<ConHelperSche
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "通过id删除小助手排班")
|
||||
@AutoLog(value = "通过id删除全科医生排班")
|
||||
@Operation(summary = "con_helper_scheduling-通过id删除", description = "con_helper_scheduling-通过id删除")
|
||||
@RequiresPermissions("consultation:con_helper_scheduling:delete")
|
||||
@DeleteMapping(value = "/delete")
|
||||
@@ -113,7 +113,7 @@ public class ConHelperSchedulingController extends JeecgController<ConHelperSche
|
||||
* @param ids
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "批量删除小助手排班")
|
||||
@AutoLog(value = "批量删除全科医生排班")
|
||||
@Operation(summary = "con_helper_scheduling-批量删除", description = "con_helper_scheduling-批量删除")
|
||||
@RequiresPermissions("consultation:con_helper_scheduling:deleteBatch")
|
||||
@DeleteMapping(value = "/deleteBatch")
|
||||
@@ -145,7 +145,7 @@ public class ConHelperSchedulingController extends JeecgController<ConHelperSche
|
||||
* @param request
|
||||
* @param conHelperScheduling
|
||||
*/
|
||||
@AutoLog(value = "导出小助手排班")
|
||||
@AutoLog(value = "导出全科医生排班")
|
||||
@RequiresPermissions("consultation:con_helper_scheduling:exportXls")
|
||||
@RequestMapping(value = "/exportXls")
|
||||
public ModelAndView exportXls(HttpServletRequest request, ConHelperScheduling conHelperScheduling) {
|
||||
@@ -159,14 +159,14 @@ public class ConHelperSchedulingController extends JeecgController<ConHelperSche
|
||||
* @param response
|
||||
* @return
|
||||
*/
|
||||
@AutoLog(value = "导入小助手排班")
|
||||
@AutoLog(value = "导入全科医生排班")
|
||||
@RequiresPermissions("consultation:con_helper_scheduling:importExcel")
|
||||
@RequestMapping(value = "/importExcel", method = RequestMethod.POST)
|
||||
public Result<?> importExcel(HttpServletRequest request, HttpServletResponse response) {
|
||||
return super.importExcel(request, response, ConHelperScheduling.class);
|
||||
}
|
||||
|
||||
@Operation(summary = "员工图文咨询选择小助手接口")
|
||||
@Operation(summary = "员工图文咨询选择全科医生接口")
|
||||
@GetMapping(value = "/chooseHelper")
|
||||
public Result<String> chooseHelper() {
|
||||
return Result.error(conHelperSchedulingService.chooseHelper());
|
||||
|
||||
+2
-2
@@ -25,7 +25,7 @@ import javax.servlet.http.HttpServletResponse;
|
||||
* @Date: 2023-08-24
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Tag(name = "consult/健康咨询/小助手管理/历史排班")
|
||||
@Tag(name = "consult/健康咨询/全科医生管理/历史排班")
|
||||
@RestController
|
||||
@RequestMapping("/consultation/conHelperSchedulingHistory")
|
||||
@Slf4j
|
||||
@@ -39,7 +39,7 @@ public class ConHelperSchedulingHistoryController extends JeecgController<ConHel
|
||||
* @return
|
||||
*/
|
||||
//@AutoLog(value = "con_helper_scheduling_history-分页列表查询")
|
||||
@Operation(summary = "获取小助手历史排班列表", description = "获取小助手历史排班列表")
|
||||
@Operation(summary = "获取全科医生历史排班列表", description = "获取全科医生历史排班列表")
|
||||
@GetMapping(value = "/list")
|
||||
public Result<IPage<ConHelperSchedulingHistoryVO>> queryPageList(ConHelperSchedulingHistoryDTO dto) {
|
||||
Page<ConHelperSchedulingHistoryVO> page = new Page<ConHelperSchedulingHistoryVO>(dto.getPageNo(), dto.getPageSize());
|
||||
|
||||
+5
-5
@@ -75,7 +75,7 @@ public class ConSessionController extends JeecgController<ConSession, IConSessio
|
||||
// 导出员工咨询专家code
|
||||
private final String USER_TO_DOCTOR_EXPORT_CODE = "UserToDoctorExportCode";
|
||||
public final String USER_TO_DOCTOR_EXPORT_CODE_V2 = "UserToDoctorExportCodeV2";
|
||||
// 导出员工咨询小助手code
|
||||
// 导出员工咨询全科医生code
|
||||
private final String USER_TO_HELP_EXPORT_CODE = "UserToHelpExportCode";
|
||||
// 导出中
|
||||
private final String EXPORT_DOING = "7";
|
||||
@@ -114,7 +114,7 @@ public class ConSessionController extends JeecgController<ConSession, IConSessio
|
||||
* @param filter 查询参数
|
||||
* @return
|
||||
*/
|
||||
@Operation(summary = "分页列表查询(小助手专用)", description = "分页列表查询(小助手专用)")
|
||||
@Operation(summary = "分页列表查询(全科医生专用)", description = "分页列表查询(全科医生专用)")
|
||||
@GetMapping(value = "/listByHelper")
|
||||
public Result<IPage<SessionExt>> listByHelper(SessionFilter filter) {
|
||||
return Result.OK(conSessionService.listByHelper(filter));
|
||||
@@ -339,7 +339,7 @@ public class ConSessionController extends JeecgController<ConSession, IConSessio
|
||||
}
|
||||
|
||||
/**
|
||||
* 导出excel(员工咨询小助手)
|
||||
* 导出excel(员工咨询全科医生)
|
||||
* @param dto
|
||||
* @return
|
||||
*/
|
||||
@@ -350,7 +350,7 @@ public class ConSessionController extends JeecgController<ConSession, IConSessio
|
||||
if (!flag) {
|
||||
return Result.error("已存在执行中的导出任务,请稍后导出或点击【查看导出任务】查看任务导出进度!");
|
||||
}
|
||||
String sheetName = "员工咨询小助手导出";
|
||||
String sheetName = "员工咨询全科医生导出";
|
||||
String fileName = sheetName + "_" + DateUtils.getDate("yyyyMMddHHmmss");
|
||||
CommonExportsInfo info = new CommonExportsInfo();
|
||||
info.setBatchNo(String.valueOf(System.currentTimeMillis()));
|
||||
@@ -359,7 +359,7 @@ public class ConSessionController extends JeecgController<ConSession, IConSessio
|
||||
info.setHandleMsg("0/0");
|
||||
info.setCreateBy(userId);
|
||||
info.setCreateDate(new Date());
|
||||
info.setExportMsg("员工咨询小助手导出");
|
||||
info.setExportMsg("员工咨询全科医生导出");
|
||||
info.setTaskCode(USER_TO_HELP_EXPORT_CODE);
|
||||
//数据导出中
|
||||
info.setExportStatus(EXPORT_DOING);
|
||||
|
||||
+38
@@ -0,0 +1,38 @@
|
||||
package com.renkang.consultation.controller;
|
||||
|
||||
import com.renkang.consultation.service.ImMsgReadLogService;
|
||||
import com.renkang.consultation.vo.ImMsgReadLogVO;
|
||||
import io.swagger.v3.oas.annotations.Operation;
|
||||
import io.swagger.v3.oas.annotations.tags.Tag;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.jeecg.common.api.vo.Result;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@Slf4j
|
||||
@Tag(name = "咨询消息已读管理")
|
||||
@RestController
|
||||
@RequestMapping("/con-message")
|
||||
@RequiredArgsConstructor
|
||||
public class ImMsgReadLogController {
|
||||
private final ImMsgReadLogService imMsgReadLogService;
|
||||
|
||||
@PostMapping("/saveReadLog")
|
||||
@Operation(summary = "记录消息已读日志", description = "记录消息已读日志")
|
||||
public Result<String> saveReadLog(@RequestBody @Valid ImMsgReadLogVO imMsgReadLogVO) {
|
||||
return Result.OK(imMsgReadLogService.saveReadLog(imMsgReadLogVO));
|
||||
}
|
||||
|
||||
@PostMapping("/findReadStatus")
|
||||
@Operation(summary = "查询消息是否已读", description = "查询消息是否已读(暂时只支持查询自定义消息类型的已读记录-医生名片)")
|
||||
public Result<Map<String,Integer>> findReadStatus(List<String> msgIdList) {
|
||||
return Result.OK(imMsgReadLogService.findReadStatus(msgIdList));
|
||||
}
|
||||
}
|
||||
+5
-5
@@ -33,9 +33,9 @@ public class ConsultationDataPageVO {
|
||||
@Schema(title = "咨询方式:1图文聊天2音视频3电话4应急")
|
||||
private String contentType;
|
||||
/**
|
||||
* 1专家2小助手
|
||||
* 1专家2全科医生
|
||||
*/
|
||||
@Schema(title = "咨询类型1员工咨询专家2员工咨询小助手3专家咨询小助手")
|
||||
@Schema(title = "咨询类型1员工咨询专家2员工咨询全科医生3专家咨询全科医生")
|
||||
@Dict(dicCode = "con_type")
|
||||
private String sessionType;
|
||||
/**
|
||||
@@ -54,12 +54,12 @@ public class ConsultationDataPageVO {
|
||||
@Schema(title = "发起者姓名")
|
||||
private String fromName;
|
||||
/**
|
||||
* 接受者姓名(可能是专家姓名 也可能是小助手名称)
|
||||
* 接受者姓名(可能是专家姓名 也可能是全科医生名称)
|
||||
*/
|
||||
@Schema(title = "接受者姓名")
|
||||
private String toName;
|
||||
/**
|
||||
* 员工单位 当咨询类型是1员工咨询专家2员工咨询小助手有值
|
||||
* 员工单位 当咨询类型是1员工咨询专家2员工咨询全科医生有值
|
||||
*/
|
||||
@Schema(title = "员工单位")
|
||||
@DBColumnInfo(commonName = DbColumnNameEnum.USER_ORG)
|
||||
@@ -75,7 +75,7 @@ public class ConsultationDataPageVO {
|
||||
@Schema(title = "员工部门Code")
|
||||
private String employeeDeptCode;
|
||||
/**
|
||||
* 员工部门 当咨询类型是1员工咨询专家2员工咨询小助手有值
|
||||
* 员工部门 当咨询类型是1员工咨询专家2员工咨询全科医生有值
|
||||
*/
|
||||
@Schema(title = "员工部门")
|
||||
@DBColumnInfo(commonName = DbColumnNameEnum.USER_DEPT)
|
||||
|
||||
+2
-2
@@ -39,7 +39,7 @@ public interface ConSessionMapper extends BaseMapper<ConSession> , MPJBaseMapper
|
||||
|
||||
|
||||
/**
|
||||
* 分页列表查询(小助手专用)
|
||||
* 分页列表查询(全科医生专用)
|
||||
*
|
||||
* @param page 分页参数
|
||||
* @param conSession 查询参数
|
||||
@@ -174,7 +174,7 @@ public interface ConSessionMapper extends BaseMapper<ConSession> , MPJBaseMapper
|
||||
|
||||
|
||||
/**
|
||||
* 小助手 超过四小时不回复就完成
|
||||
* 全科医生 超过四小时不回复就完成
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
|
||||
+9
@@ -0,0 +1,9 @@
|
||||
package com.renkang.consultation.mapper;
|
||||
|
||||
import com.github.yulichang.base.MPJBaseMapper;
|
||||
import com.renkang.consultation.entity.ImMsgReadLog;
|
||||
import org.apache.ibatis.annotations.Mapper;
|
||||
|
||||
@Mapper
|
||||
public interface ImMsgReadLogMapper extends MPJBaseMapper<ImMsgReadLog> {
|
||||
}
|
||||
+2
-2
@@ -20,14 +20,14 @@ public interface IConHelperSchedulingService extends IService<ConHelperSchedulin
|
||||
String chooseHelper();
|
||||
|
||||
/**
|
||||
* 小助手排班列表
|
||||
* 全科医生排班列表
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
List<ConHelperSchedulingCustomVO> listCustom();
|
||||
|
||||
/**
|
||||
* 小助手修改排班
|
||||
* 全科医生修改排班
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
|
||||
+4
-4
@@ -23,7 +23,7 @@ public interface IConHelperService extends IService<ConHelper> {
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param conHelperExAndUser 小助手信息及用户基础信息
|
||||
* @param conHelperExAndUser 全科医生信息及用户基础信息
|
||||
* @return
|
||||
*/
|
||||
Result<String> saveHelperUser(ConHelperExAndUser conHelperExAndUser);
|
||||
@@ -31,13 +31,13 @@ public interface IConHelperService extends IService<ConHelper> {
|
||||
/**
|
||||
* 编辑
|
||||
*
|
||||
* @param conHelperExAndUser 小助手信息及用户基础信息
|
||||
* @param conHelperExAndUser 全科医生信息及用户基础信息
|
||||
* @return
|
||||
*/
|
||||
Result<String> updateByHelperUser(ConHelperExAndUser conHelperExAndUser);
|
||||
|
||||
/**
|
||||
* 小助手排班人员选择
|
||||
* 全科医生排班人员选择
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@@ -55,7 +55,7 @@ public interface IConHelperService extends IService<ConHelper> {
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id 小助手id
|
||||
* @param id 全科医生id
|
||||
* @return
|
||||
*/
|
||||
ConHelperExAndUser getByHelperUser(String id);
|
||||
|
||||
+22
@@ -0,0 +1,22 @@
|
||||
package com.renkang.consultation.service;
|
||||
|
||||
import com.renkang.consultation.vo.ImMsgReadLogVO;
|
||||
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
public interface ImMsgReadLogService {
|
||||
/**
|
||||
* 记录消息已读日志
|
||||
* @param imMsgReadLogVO
|
||||
* @return
|
||||
*/
|
||||
String saveReadLog(ImMsgReadLogVO imMsgReadLogVO);
|
||||
|
||||
/**
|
||||
* 查询消息是否已读
|
||||
* @param msgIdList
|
||||
* @return
|
||||
*/
|
||||
Map<String,Integer> findReadStatus(List<String> msgIdList);
|
||||
}
|
||||
+3
-3
@@ -86,11 +86,11 @@ public class ConHelperSchedulingServiceImpl extends ServiceImpl<ConHelperSchedul
|
||||
}
|
||||
}
|
||||
}
|
||||
return "没有排班小助手!";
|
||||
return "没有排班全科医生!";
|
||||
}
|
||||
|
||||
/**
|
||||
* 小助手排班列表
|
||||
* 全科医生排班列表
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@@ -174,7 +174,7 @@ public class ConHelperSchedulingServiceImpl extends ServiceImpl<ConHelperSchedul
|
||||
|
||||
|
||||
/**
|
||||
* 小助手修改排班
|
||||
* 全科医生修改排班
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
|
||||
+11
-11
@@ -78,7 +78,7 @@ public class ConHelperServiceImpl extends ServiceImpl<ConHelperMapper, ConHelper
|
||||
/**
|
||||
* 添加
|
||||
*
|
||||
* @param conHelperExAndUser 小助手信息及用户基础信息
|
||||
* @param conHelperExAndUser 全科医生信息及用户基础信息
|
||||
* @return
|
||||
*/
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@@ -137,9 +137,9 @@ public class ConHelperServiceImpl extends ServiceImpl<ConHelperMapper, ConHelper
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新小助手信息及用户基础信息
|
||||
* 更新全科医生信息及用户基础信息
|
||||
*
|
||||
* @param conHelperExAndUser 小助手信息及用户基础信息
|
||||
* @param conHelperExAndUser 全科医生信息及用户基础信息
|
||||
* @return 返回操作结果
|
||||
*/
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
@@ -163,7 +163,7 @@ public class ConHelperServiceImpl extends ServiceImpl<ConHelperMapper, ConHelper
|
||||
redisUtil.del("sys:cache:encrypt:user::" + conHelperExAndUser.getConHelper().getId());
|
||||
sysBaseAPI.updateUserToEx(sysUserModel);
|
||||
|
||||
// 获取并设置更新的小助手信息
|
||||
// 获取并设置更新的全科医生信息
|
||||
ConHelper conHelper = new ConHelper();
|
||||
BeanUtils.copyProperties(conHelperExAndUser.getSysUserModel(), conHelper);
|
||||
BeanUtils.copyProperties(conHelperExAndUser.getConHelper(), conHelper);
|
||||
@@ -172,16 +172,16 @@ public class ConHelperServiceImpl extends ServiceImpl<ConHelperMapper, ConHelper
|
||||
conHelper.setUserName(conHelperExAndUser.getConHelper().getHelperName());
|
||||
conHelper.setUpdateTime(new Date());
|
||||
|
||||
// 更新小助手信息
|
||||
// 更新全科医生信息
|
||||
updateHelper(conHelper);
|
||||
|
||||
return Result.ok("修改成功");
|
||||
}
|
||||
|
||||
/**
|
||||
* 更新小助手信息
|
||||
* 更新全科医生信息
|
||||
*
|
||||
* @param conHelper 小助手信息
|
||||
* @param conHelper 全科医生信息
|
||||
*/
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void updateHelper(ConHelper conHelper) {
|
||||
@@ -200,7 +200,7 @@ public class ConHelperServiceImpl extends ServiceImpl<ConHelperMapper, ConHelper
|
||||
}
|
||||
|
||||
/**
|
||||
* 小助手排班人员选择
|
||||
* 全科医生排班人员选择
|
||||
*
|
||||
* @return
|
||||
*/
|
||||
@@ -278,12 +278,12 @@ public class ConHelperServiceImpl extends ServiceImpl<ConHelperMapper, ConHelper
|
||||
/**
|
||||
* 通过id查询
|
||||
*
|
||||
* @param id 小助手id
|
||||
* @param id 全科医生id
|
||||
* @return
|
||||
*/
|
||||
@Override
|
||||
public ConHelperExAndUser getByHelperUser(String id) {
|
||||
//查询小助手基础信息
|
||||
//查询全科医生基础信息
|
||||
LoginUser user = sysBaseAPI.getUserById(id);
|
||||
ConHelperExAndUser conHelperExAndUser = new ConHelperExAndUser();
|
||||
SysUserModel sysUserModel = new SysUserModel();
|
||||
@@ -293,7 +293,7 @@ public class ConHelperServiceImpl extends ServiceImpl<ConHelperMapper, ConHelper
|
||||
BeanUtils.copyProperties(sysUserModel, userVO);
|
||||
conHelperExAndUser.setSysUserModel(userVO);
|
||||
|
||||
//查询小助手信息
|
||||
//查询全科医生信息
|
||||
ConHelper conHelper = conHelperMapper.selectById(id);
|
||||
//部门处理
|
||||
List<ConHelper> conHelperList = new ArrayList<>();
|
||||
|
||||
+4
-4
@@ -447,9 +447,9 @@ public class ConSessionServiceImpl extends ServiceImpl<ConSessionMapper, ConSess
|
||||
/**
|
||||
* 专家处理
|
||||
* 2023.07.07
|
||||
* 当员工咨询专家时(sessioType=1) 员工为 fromAccount 专家为 toAccount 此时小助手第三方介入为 thirdAccount
|
||||
* 当员工咨询小助手时(sessioType=2) 员工为 fromAccount 小助手为 toAccount 此时不会介入专家(thirdAccount 为 null) 当小助手推送专家时会发起员工咨询专家的会话
|
||||
* 当专家咨询小助手时(sessioType=3) 专家为 fromAccount 小助手为 toAccount
|
||||
* 当员工咨询专家时(sessioType=1) 员工为 fromAccount 专家为 toAccount 此时全科医生第三方介入为 thirdAccount
|
||||
* 当员工咨询全科医生时(sessioType=2) 员工为 fromAccount 全科医生为 toAccount 此时不会介入专家(thirdAccount 为 null) 当全科医生推送专家时会发起员工咨询专家的会话
|
||||
* 当专家咨询全科医生时(sessioType=3) 专家为 fromAccount 全科医生为 toAccount
|
||||
*
|
||||
* @param records 会话记录列表
|
||||
* @param sessionType 来源类型
|
||||
@@ -510,7 +510,7 @@ public class ConSessionServiceImpl extends ServiceImpl<ConSessionMapper, ConSess
|
||||
}
|
||||
|
||||
if (!"1".equals(record.getSessionType())) {
|
||||
// 小助手
|
||||
// 全科医生
|
||||
ConHelper helperInfo = helperInfoMap.get(record.getToAccount());
|
||||
if (helperInfo != null) {
|
||||
updateRecordWithHelperInfo(record, helperInfo);
|
||||
|
||||
+62
@@ -0,0 +1,62 @@
|
||||
package com.renkang.consultation.service.impl;
|
||||
|
||||
import com.github.yulichang.wrapper.MPJLambdaWrapper;
|
||||
import com.renkang.consultation.entity.ImMsgReadLog;
|
||||
import com.renkang.consultation.mapper.ImMsgReadLogMapper;
|
||||
import com.renkang.consultation.service.ImMsgReadLogService;
|
||||
import com.renkang.consultation.vo.ImMsgReadLogVO;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.jeecg.common.exception.ExceptionAssertsUtil;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.HashMap;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
@Service
|
||||
@RequiredArgsConstructor
|
||||
public class ImMsgReadLogServiceImpl implements ImMsgReadLogService {
|
||||
private final ImMsgReadLogMapper imMsgReadLogMapper;
|
||||
|
||||
@Override
|
||||
public String saveReadLog(ImMsgReadLogVO imMsgReadLogVO) {
|
||||
MPJLambdaWrapper<ImMsgReadLog> wrapper = new MPJLambdaWrapper<>();
|
||||
wrapper.eq(ImMsgReadLog::getMsgId, imMsgReadLogVO.getMsgId());
|
||||
wrapper.eq(ImMsgReadLog::getGroupId, imMsgReadLogVO.getGroupId());
|
||||
ImMsgReadLog msgReadLog = imMsgReadLogMapper.selectOne(wrapper);
|
||||
if(msgReadLog == null) {
|
||||
msgReadLog = new ImMsgReadLog();
|
||||
msgReadLog.setGroupId(imMsgReadLogVO.getGroupId());
|
||||
msgReadLog.setMsgId(imMsgReadLogVO.getMsgId());
|
||||
msgReadLog.setReadTime(new Date());
|
||||
msgReadLog.setToAccount(imMsgReadLogVO.getToAccount());
|
||||
msgReadLog.setFromAccount(imMsgReadLogVO.getFromAccount());
|
||||
msgReadLog.setReadCount(1);
|
||||
imMsgReadLogMapper.insert(msgReadLog);
|
||||
}else {
|
||||
//因为目前用于医生名片的已读且只能点一次,暂时这样提示
|
||||
ExceptionAssertsUtil.fail("医生名片已失效");
|
||||
}
|
||||
return "操作成功";
|
||||
}
|
||||
|
||||
@Override
|
||||
public Map<String,Integer> findReadStatus(List<String> msgIdList) {
|
||||
Map<String,Integer> map = new HashMap<>();
|
||||
MPJLambdaWrapper<ImMsgReadLog> wrapper = new MPJLambdaWrapper<>();
|
||||
wrapper.in(ImMsgReadLog::getMsgId, msgIdList);
|
||||
Map<String,ImMsgReadLog> logMap = imMsgReadLogMapper.selectList(wrapper).stream()
|
||||
.collect(Collectors.toMap(ImMsgReadLog::getMsgId, x -> x));
|
||||
for (String msgId : msgIdList) {
|
||||
ImMsgReadLog log = logMap.get(msgId);
|
||||
if(log == null) {
|
||||
map.put(msgId, 0);
|
||||
}else {
|
||||
map.put(msgId, log.getReadCount());
|
||||
}
|
||||
}
|
||||
return map;
|
||||
}
|
||||
}
|
||||
+6
-6
@@ -36,8 +36,8 @@ public class HelperSchedulingHistoryJob {
|
||||
String clientSign = jsonObject.getString("clientSign");
|
||||
|
||||
ClientSignThreadLocal.setClientSign(clientSign);
|
||||
XxlJobHelper.log("开始记录小助手排班历史");
|
||||
log.info("开始记录小助手排班历史");
|
||||
XxlJobHelper.log("开始记录全科医生排班历史");
|
||||
log.info("开始记录全科医生排班历史");
|
||||
try {
|
||||
//获取昨天的日期
|
||||
Date yesterday = DateUtils.dateAddDay(new Date(), -1);
|
||||
@@ -53,12 +53,12 @@ public class HelperSchedulingHistoryJob {
|
||||
historyList.add(history);
|
||||
});
|
||||
historyService.saveBatch(historyList);
|
||||
XxlJobHelper.log("结束记录小助手排班历史");
|
||||
log.info("结束记录小助手排班历史");
|
||||
XxlJobHelper.log("结束记录全科医生排班历史");
|
||||
log.info("结束记录全科医生排班历史");
|
||||
return ReturnT.SUCCESS;
|
||||
} catch (Exception e) {
|
||||
XxlJobHelper.log("记录小助手排班历史失败");
|
||||
log.error("记录小助手排班历史失败", e);
|
||||
XxlJobHelper.log("记录全科医生排班历史失败");
|
||||
log.error("记录全科医生排班历史失败", e);
|
||||
return ReturnT.FAIL;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -262,7 +262,7 @@ public class TXController {
|
||||
String personType = loginUser.getPersonType();
|
||||
String aa = "";
|
||||
/* if (StringUtils.equals(personType, "2")) {
|
||||
aa = "(小助手)";
|
||||
aa = "(全科医生)";
|
||||
}*/
|
||||
if (StringUtils.equals(personType, "3")) {
|
||||
aa = "(专家)";
|
||||
@@ -302,7 +302,7 @@ public class TXController {
|
||||
String personType = loginUser.getPersonType();
|
||||
String aa = "";
|
||||
/* if (StringUtils.equals(personType, "2")) {
|
||||
aa = "(小助手)";
|
||||
aa = "(全科医生)";
|
||||
}*/
|
||||
if (StringUtils.equals(personType, "3")) {
|
||||
aa = "(专家)";
|
||||
|
||||
+10
-10
@@ -570,10 +570,10 @@ public class WatchDataServiceImpl extends ServiceImpl<WatchDataMapper, WatchData
|
||||
.filter(f -> ObjectUtil.isNotNull(f.getMinValue()))
|
||||
.mapToInt(WatchStatUserInfoDayHeartRate::getMinValue).min().orElse(0);
|
||||
// 和
|
||||
int sum = list.stream()
|
||||
.filter(f -> ObjectUtil.isNotNull(f.getAvgValue()))
|
||||
.mapToInt(WatchStatUserInfoDayHeartRate::getAvgValue).sum();
|
||||
|
||||
List<WatchStatUserInfoDayHeartRate> heartRateList = list.stream()
|
||||
.filter(f -> ObjectUtil.isNotNull(f.getAvgValue()) && f.getAvgValue() > 0)
|
||||
.collect(Collectors.toList());
|
||||
int sum = heartRateList.stream().mapToInt(WatchStatUserInfoDayHeartRate::getAvgValue).sum();
|
||||
// 最大值
|
||||
int skinMax = list.stream()
|
||||
.filter(f -> ObjectUtil.isNotNull(f.getSilenceMaxValue()))
|
||||
@@ -583,17 +583,17 @@ public class WatchDataServiceImpl extends ServiceImpl<WatchDataMapper, WatchData
|
||||
.filter(f -> ObjectUtil.isNotNull(f.getSilenceMinValue()))
|
||||
.mapToInt(WatchStatUserInfoDayHeartRate::getSilenceMinValue).min().orElse(0);
|
||||
// 和
|
||||
int skinSum = list.stream()
|
||||
.filter(f -> ObjectUtil.isNotNull(f.getSilenceAvgValue()))
|
||||
.mapToInt(WatchStatUserInfoDayHeartRate::getSilenceAvgValue).sum();
|
||||
|
||||
List<WatchStatUserInfoDayHeartRate> silenceList = list.stream()
|
||||
.filter(f -> ObjectUtil.isNotNull(f.getSilenceAvgValue()) && f.getSilenceAvgValue() > 0)
|
||||
.collect(Collectors.toList());
|
||||
int skinSum = silenceList.stream().mapToInt(WatchStatUserInfoDayHeartRate::getSilenceAvgValue).sum();
|
||||
stat.setMax(max);
|
||||
stat.setMin(min);
|
||||
stat.setAvg((sum / list.size()));
|
||||
stat.setAvg((sum / heartRateList.size()));
|
||||
|
||||
stat.setSilenceMax(skinMax);
|
||||
stat.setSilenceMin(skinMin);
|
||||
stat.setSilenceAvg(skinSum / list.size());
|
||||
stat.setSilenceAvg(skinSum / silenceList.size());
|
||||
|
||||
return stat;
|
||||
}
|
||||
|
||||
@@ -142,10 +142,10 @@ public class SysUserModel {
|
||||
@Schema(title = "身份证")
|
||||
private String idCard;
|
||||
/**
|
||||
* 人员类型 1:员工 2: 小助手 3: 专家 4: 医疗点 5: 操作人员 6: 专业人员 7:驻场人员 8:其他 9:医院管理员
|
||||
* 人员类型 1:员工 2: 全科医生 3: 专家 4: 医疗点 5: 操作人员 6: 专业人员 7:驻场人员 8:其他 9:医院管理员
|
||||
* 10: 医院体检医生 11:医院前台 12: 健康室管理员 13: 健康打卡管理员
|
||||
*/
|
||||
@Schema(title = "人员类型", description = "1:员工 2: 小助手 3: 专家 4: 医疗点 5: 操作人员 6: 专业人员 7:驻场人员 8:其他 9:医院管理员 10: 医院体检医生 11:医院前台 12: 健康室管理员 13: 健康打卡管理员")
|
||||
@Schema(title = "人员类型", description = "1:员工 2: 全科医生 3: 专家 4: 医疗点 5: 操作人员 6: 专业人员 7:驻场人员 8:其他 9:医院管理员 10: 医院体检医生 11:医院前台 12: 健康室管理员 13: 健康打卡管理员")
|
||||
@Dict(dicCode = "p_type")
|
||||
private String personType;
|
||||
|
||||
|
||||
+3
-3
@@ -66,10 +66,10 @@ public class SysNotice implements Serializable {
|
||||
@Schema(title = "发布状态(0未发布,1已发布,2已撤销)")
|
||||
private String sendStatus;
|
||||
/**
|
||||
* 所属角色(1:员工 2: 小助手 3: 专家 4: 医疗点 5: 操作人员 6: 专业人员 7:驻场人员 8:其他 9:医院管理员 10: 医院体检医生 11:医院前台 12: 健康室管理员 13: 健康打卡管理员)
|
||||
* 所属角色(1:员工 2: 全科医生 3: 专家 4: 医疗点 5: 操作人员 6: 专业人员 7:驻场人员 8:其他 9:医院管理员 10: 医院体检医生 11:医院前台 12: 健康室管理员 13: 健康打卡管理员)
|
||||
*/
|
||||
@Excel(name = "所属角色(1:员工 2: 小助手 3: 专家 4: 医疗点 5: 操作人员 6: 专业人员 7:驻场人员 8:其他 9:医院管理员 10: 医院体检医生 11:医院前台 12: 健康室管理员 13: 健康打卡管理员)", width = 15)
|
||||
@Schema(title = "所属角色(1:员工 2: 小助手 3: 专家 4: 医疗点 5: 操作人员 6: 专业人员 7:驻场人员 8:其他 9:医院管理员 10: 医院体检医生 11:医院前台 12: 健康室管理员 13: 健康打卡管理员)")
|
||||
@Excel(name = "所属角色(1:员工 2: 全科医生 3: 专家 4: 医疗点 5: 操作人员 6: 专业人员 7:驻场人员 8:其他 9:医院管理员 10: 医院体检医生 11:医院前台 12: 健康室管理员 13: 健康打卡管理员)", width = 15)
|
||||
@Schema(title = "所属角色(1:员工 2: 全科医生 3: 专家 4: 医疗点 5: 操作人员 6: 专业人员 7:驻场人员 8:其他 9:医院管理员 10: 医院体检医生 11:医院前台 12: 健康室管理员 13: 健康打卡管理员)")
|
||||
private String personType;
|
||||
/**
|
||||
* 发布时间
|
||||
|
||||
Reference in New Issue
Block a user