| | |
| | | // returnQues.setCode(null); |
| | | List<IvrLibaTemplateScriptVO> backQusetRedis = redisCache.getCacheObject(userId + "backQuset"); |
| | | returnQues.setContent(JSON.toJSONString(backQusetRedis)); |
| | | returnQues.setJsy("感谢您的耐心回答,再见"); |
| | | returnQues.setJsy(ivrLibaTemplateVO1.getRevisitAfter()); |
| | | redisCache.setCacheObject(userId + "returnQues", returnQues, 120, TimeUnit.MINUTES); |
| | | redisCache.setCacheObject(userId + "isOver", 1, 120, TimeUnit.MINUTES); |
| | | |
| | |
| | | redisCache.setCacheObject(userId + "noVoice", noVoice2, 120, TimeUnit.MINUTES); |
| | | } |
| | | } else { |
| | | //对回答的问题,进行正则匹配(这里只针对选择题,其它题型不行) |
| | | //对回答的问题,进行正则匹配(这里只针对选择题,其它题型不行)x |
| | | for (int j = 0; j < ivrLibaTemplateScriptVO.getIvrLibaScriptTargetoptionList().size(); j++) { |
| | | //包含 |
| | | Matcher matcher = null; |
| | |
| | | redisCache.setCacheObject(userId + "noVoice", 0, 120, TimeUnit.MINUTES); |
| | | //获取下一题 |
| | | Integer nextQuestion = ivrLibaTemplateScriptVO.getIvrLibaScriptTargetoptionList().get(j).getNextQuestion(); |
| | | for (IvrLibaTemplateScriptVO script : ivrLibaTemplateScriptVOList) { |
| | | if (script.getTargetid() == nextQuestion) { |
| | | QuestionMessage returnQues = new QuestionMessage(); |
| | | returnQues.setNowQuestion(script); |
| | | redisCache.setCacheObject(userId + "returnQues", returnQues, 120, TimeUnit.MINUTES); |
| | | break; |
| | | if (nextQuestion > ivrLibaTemplateScriptVOList.size()) { |
| | | //如果下一题没有了,就结束了 |
| | | QuestionMessage returnQues = new QuestionMessage(); |
| | | List<IvrLibaTemplateScriptVO> backQusetRedis = redisCache.getCacheObject(userId + "backQuset"); |
| | | returnQues.setContent(JSON.toJSONString(backQusetRedis)); |
| | | returnQues.setJsy(ivrLibaTemplateVO1.getRevisitAfter()); |
| | | redisCache.setCacheObject(userId + "returnQues", returnQues, 120, TimeUnit.MINUTES); |
| | | redisCache.setCacheObject(userId + "isOver", 1, 120, TimeUnit.MINUTES); |
| | | } else { |
| | | for (IvrLibaTemplateScriptVO script : ivrLibaTemplateScriptVOList) { |
| | | if (script.getTargetid() == nextQuestion) { |
| | | QuestionMessage returnQues = new QuestionMessage(); |
| | | returnQues.setNowQuestion(script); |
| | | redisCache.setCacheObject(userId + "returnQues", returnQues, 120, TimeUnit.MINUTES); |
| | | break; |
| | | } |
| | | } |
| | | } |
| | | break; |
| | |
| | | * 新增或修改指标信息 |
| | | */ |
| | | @ApiOperation("新增或修改指标信息") |
| | | @PreAuthorize("@ss.hasPermi('system:target:edit')") |
| | | @Log(title = "指标选项库", businessType = BusinessType.UPDATE) |
| | | @PostMapping("/saveOrupdateIvrLibaTarget") |
| | | public AjaxResult saveOrupdateIvrLibaTarget(@RequestBody IvrLibaTargetVO ivrLibaTargetVO) { |
| | |
| | | // 过滤请求 |
| | | .authorizeRequests() |
| | | // 对于登录login 注册register 验证码captchaImage 允许匿名访问 |
| | | .antMatchers("/login", "/register", "/captchaImage", "/qrcode/generateStaticHtml", "/qrcode/getQRcode", "/qrcode/getFormDate", "/chat", "/system/file/admin/uploadFile", "/smartor/dingtalk/sendNotification", "/patient/read/patientInfo","/socket","/API_ESB_Service","/API_ESB_Service/Run","/magic/web/**","/smartor/taskcall/phoneCallBack").permitAll() |
| | | .antMatchers("/login", "/register", "/captchaImage", "/qrcode/generateStaticHtml", "/qrcode/getQRcode", "/qrcode/getFormDate", "/chat", "/system/file/admin/uploadFile", "/smartor/dingtalk/sendNotification", "/patient/read/patientInfo","/socket","/API_ESB_Service","/API_ESB_Service/Run","/magic/web/**","/smartor/tasksingle/phoneCallBack").permitAll() |
| | | // 静态资源,可匿名访问 |
| | | .antMatchers(HttpMethod.GET, "/", "/*.html", "/**/*.html", "/**/*.css", "/**/*.js", "/profile/**").permitAll().antMatchers("/swagger-ui.html", "/swagger-resources/**", "/webjars/**", "/*/api-docs", "/druid/**").permitAll() |
| | | // 除上面外的所有请求全部需要鉴权认证 |
| | |
| | | @Excel(name = "类型(1 宣教、2 医技)") |
| | | @ApiModelProperty(value = "类型(1 宣教、2 医技)") |
| | | private String type; |
| | | |
| | | /** |
| | | * 发送日期 |
| | | */ |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | @Excel(name = " 发送日期 ", width = 30, dateFormat = "yyyy-MM-dd") |
| | | @ApiModelProperty(value = "发送日期") |
| | | private Date senddate; |
| | | |
| | | /** |
| | | * 上午开始发送时间限制 |
| | | */ |
| | | @Excel(name = " 上午开始发送时间限制 ") |
| | | @ApiModelProperty(value = "上午开始发送时间限制") |
| | | private String sendlimitabegin; |
| | | |
| | | /** |
| | | * 上午结束发送时间限制 |
| | | */ |
| | | @Excel(name = " 上午结束发送时间限制 ") |
| | | @ApiModelProperty(value = "上午结束发送时间限制") |
| | | private String sendlimitaend; |
| | | |
| | | /** |
| | | * 下午开始发送时间限制 |
| | | */ |
| | | @Excel(name = " 下午开始发送时间限制 ") |
| | | @ApiModelProperty(value = "下午开始发送时间限制") |
| | | private String sendlimitpbegin; |
| | | |
| | | /** |
| | | * 下午结束发送时间限制 |
| | | */ |
| | | @Excel(name = " 下午结束发送时间限制 ") |
| | | @ApiModelProperty(value = "下午结束发送时间限制") |
| | | private String sendlimitpend; |
| | | |
| | | /** |
| | | * 晚上开始发送时间限制 |
| | | */ |
| | | @Excel(name = " 晚上开始发送时间限制 ") |
| | | @ApiModelProperty(value = "晚上开始发送时间限制") |
| | | private String sendlimitnbegin; |
| | | |
| | | /** |
| | | * 晚上结束发送时间限制 |
| | | */ |
| | | @Excel(name = " 晚上结束发送时间限制 ") |
| | | @ApiModelProperty(value = "晚上结束发送时间限制") |
| | | private String sendlimitnend; |
| | | } |
| | |
| | | * @author ruoyi |
| | | * @date 2024-04-16 |
| | | */ |
| | | @ApiModel(value = "IvrTask", description = "宣教单一任务对象 ") |
| | | @ApiModel(value = "HeTaskSingleVO", description = "宣教单一任务对象 ") |
| | | @Data |
| | | public class HeTaskSingleVO extends BaseEntity { |
| | | private static final long serialVersionUID = 1L; |
| | |
| | | private String type; |
| | | |
| | | /** |
| | | * 发送日期 |
| | | */ |
| | | @JsonFormat(pattern = "yyyy-MM-dd") |
| | | @Excel(name = " 发送日期 ", width = 30, dateFormat = "yyyy-MM-dd") |
| | | @ApiModelProperty(value = "发送日期") |
| | | private Date senddate; |
| | | |
| | | /** |
| | | * 上午开始发送时间限制 |
| | | */ |
| | | @Excel(name = " 上午开始发送时间限制 ") |
| | | @ApiModelProperty(value = "上午开始发送时间限制") |
| | | private String sendlimitabegin; |
| | | |
| | | /** |
| | | * 上午结束发送时间限制 |
| | | */ |
| | | @Excel(name = " 上午结束发送时间限制 ") |
| | | @ApiModelProperty(value = "上午结束发送时间限制") |
| | | private String sendlimitaend; |
| | | |
| | | /** |
| | | * 下午开始发送时间限制 |
| | | */ |
| | | @Excel(name = " 下午开始发送时间限制 ") |
| | | @ApiModelProperty(value = "下午开始发送时间限制") |
| | | private String sendlimitpbegin; |
| | | |
| | | /** |
| | | * 下午结束发送时间限制 |
| | | */ |
| | | @Excel(name = " 下午结束发送时间限制 ") |
| | | @ApiModelProperty(value = "下午结束发送时间限制") |
| | | private String sendlimitpend; |
| | | |
| | | /** |
| | | * 晚上开始发送时间限制 |
| | | */ |
| | | @Excel(name = " 晚上开始发送时间限制 ") |
| | | @ApiModelProperty(value = "晚上开始发送时间限制") |
| | | private String sendlimitnbegin; |
| | | |
| | | /** |
| | | * 晚上结束发送时间限制 |
| | | */ |
| | | @Excel(name = " 晚上结束发送时间限制 ") |
| | | @ApiModelProperty(value = "晚上结束发送时间限制") |
| | | private String sendlimitnend; |
| | | |
| | | /** |
| | | * 患者与单一任务关联表集合 |
| | | */ |
| | | @Excel(name = " 宣患者与单一任务关联表集合") |
| | |
| | | private String name; |
| | | |
| | | /** |
| | | * 疾病名称 |
| | | */ |
| | | @ApiModelProperty("疾病名称") |
| | | @Excel(name = " 疾病名称 ") |
| | | private String diagname; |
| | | |
| | | /** |
| | | * 证件号码 |
| | | */ |
| | | @ApiModelProperty("证件号码") |
| | |
| | | @ApiModelProperty("手机号码") |
| | | @Excel(name = " 手机号码 ") |
| | | private String telcode; |
| | | |
| | | /** |
| | | * 手机号码 |
| | | */ |
| | | @ApiModelProperty("手机号码") |
| | | @Excel(name = " 手机号码 ") |
| | | private String leaveicd10code; |
| | | |
| | | /** |
| | | * 标签ID |
| | |
| | | private String visitno; |
| | | |
| | | /** |
| | | * 院区名称 |
| | | */ |
| | | @ApiModelProperty(value = " 院区名称 ") |
| | | private String hospitaldistrictname; |
| | | |
| | | /** |
| | | * pageNum |
| | | */ |
| | | @ApiModelProperty(value = "pageNum") |
| | |
| | | patTaskRelevance.setAddr(ivrTaskcall1.getAddr()); |
| | | patTaskRelevance.setDiagname(ivrTaskcall1.getDiagname()); |
| | | patTaskRelevances.add(patTaskRelevance); |
| | | } else if (ivrTaskcall1.getHospType().equals("2")) { |
| | | } |
| | | if (ivrTaskcall1.getHospType().equals("2")) { |
| | | log.info("随访查询为出院,{}", ivrTaskcall1.getHospType()); |
| | | patTaskRelevance.setName(ivrTaskcall1.getSendname()); |
| | | patTaskRelevance.setAge(ivrTaskcall1.getAge()); |
| | |
| | | <result property="type" column="type"/> |
| | | <result property="sendType" column="send_type"/> |
| | | <result property="sendTimeSlot" column="send_time_slot"/> |
| | | <result property="senddate" column="senddate"/> |
| | | <result property="sendlimitabegin" column="sendlimitabegin"/> |
| | | <result property="sendlimitaend" column="sendlimitaend"/> |
| | | <result property="sendlimitpbegin" column="sendlimitpbegin"/> |
| | | <result property="sendlimitpend" column="sendlimitpend"/> |
| | | <result property="sendlimitnbegin" column="sendlimitnbegin"/> |
| | | <result property="sendlimitnend" column="sendlimitnend"/> |
| | | </resultMap> |
| | | |
| | | <sql id="selectHeTaskSingleVo"> |
| | |
| | | bedno, |
| | | send_type, |
| | | type, |
| | | senddate, |
| | | sendlimitabegin, |
| | | sendlimitaend, |
| | | sendlimitpbegin, |
| | | sendlimitpend, |
| | | sendlimitnbegin, |
| | | sendlimitnend, |
| | | send_time_slot |
| | | from he_task_single |
| | | </sql> |
| | |
| | | <if test="sendType != null and sendType != ''">and send_type = #{sendType}</if> |
| | | <if test="sendTimeSlot != null and sendTimeSlot != ''">and send_time_slot = #{sendTimeSlot}</if> |
| | | <if test="type != null and type != ''">and type = #{type}</if> |
| | | <if test="senddate != null ">and senddate = #{senddate}</if> |
| | | <if test="sendlimitabegin != null and sendlimitabegin != ''">and sendlimitabegin = #{sendlimitabegin}</if> |
| | | <if test="sendlimitaend != null and sendlimitaend != ''">and sendlimitaend = #{sendlimitaend}</if> |
| | | <if test="sendlimitpbegin != null and sendlimitpbegin != ''">and sendlimitpbegin = #{sendlimitpbegin}</if> |
| | | <if test="sendlimitpend != null and sendlimitpend != ''">and sendlimitpend = #{sendlimitpend}</if> |
| | | <if test="sendlimitnbegin != null and sendlimitnbegin != ''">and sendlimitnbegin = #{sendlimitnbegin}</if> |
| | | <if test="sendlimitnend != null and sendlimitnend != ''">and sendlimitnend = #{sendlimitnend}</if> |
| | | </where> |
| | | </select> |
| | | |
| | |
| | | <if test="sendType != null">send_type,</if> |
| | | <if test="sendTimeSlot != null">send_time_slot,</if> |
| | | <if test="type != null">type,</if> |
| | | <if test="senddate != null">senddate,</if> |
| | | <if test="sendlimitabegin != null">sendlimitabegin,</if> |
| | | <if test="sendlimitaend != null">sendlimitaend,</if> |
| | | <if test="sendlimitpbegin != null">sendlimitpbegin,</if> |
| | | <if test="sendlimitpend != null">sendlimitpend,</if> |
| | | <if test="sendlimitnbegin != null">sendlimitnbegin,</if> |
| | | <if test="sendlimitnend != null">sendlimitnend,</if> |
| | | </trim> |
| | | <trim prefix="values (" suffix=")" suffixOverrides=","> |
| | | <if test="svrtaskid != null">#{svrtaskid},</if> |
| | |
| | | <if test="sendType != null">#{sendType},</if> |
| | | <if test="sendTimeSlot != null">#{sendTimeSlot},</if> |
| | | <if test="type != null">#{type},</if> |
| | | <if test="senddate != null">#{senddate},</if> |
| | | <if test="sendlimitabegin != null">#{sendlimitabegin},</if> |
| | | <if test="sendlimitaend != null">#{sendlimitaend},</if> |
| | | <if test="sendlimitpbegin != null">#{sendlimitpbegin},</if> |
| | | <if test="sendlimitpend != null">#{sendlimitpend},</if> |
| | | <if test="sendlimitnbegin != null">#{sendlimitnbegin},</if> |
| | | <if test="sendlimitnend != null">#{sendlimitnend},</if> |
| | | </trim> |
| | | </insert> |
| | | |
| | |
| | | <if test="sendType != null">send_type = #{sendType},</if> |
| | | <if test="sendTimeSlot != null">send_time_slot = #{sendTimeSlot},</if> |
| | | <if test="type != null">type = #{type},</if> |
| | | <if test="senddate != null">senddate = #{senddate},</if> |
| | | <if test="sendlimitabegin != null">sendlimitabegin = #{sendlimitabegin},</if> |
| | | <if test="sendlimitaend != null">sendlimitaend = #{sendlimitaend},</if> |
| | | <if test="sendlimitpbegin != null">sendlimitpbegin = #{sendlimitpbegin},</if> |
| | | <if test="sendlimitpend != null">sendlimitpend = #{sendlimitpend},</if> |
| | | <if test="sendlimitnbegin != null">sendlimitnbegin = #{sendlimitnbegin},</if> |
| | | <if test="sendlimitnend != null">sendlimitnend = #{sendlimitnend},</if> |
| | | </trim> |
| | | where id = #{id} |
| | | </update> |
| | |
| | | resultMap="PatArchiveResult"> |
| | | |
| | | select |
| | | c.tagname as tag, |
| | | b.tagid as tagid, |
| | | -- c.tagname as tag, |
| | | -- b.tagid as tagid, |
| | | a.patid, |
| | | a.name, |
| | | d.deptname, |
| | |
| | | a.isupload, |
| | | a.upload_time, |
| | | a.pattype, |
| | | d.bedno |
| | | from pat_archive a,pat_archivetag b ,base_tag c,pat_med_inhosp d |
| | | d.bed_no |
| | | -- from pat_archive a,pat_archivetag b ,base_tag c,pat_med_inhosp d |
| | | from pat_archive a,pat_med_inhosp d |
| | | <where> |
| | | a.patid = b.patid and b.tagid = c.tagid and a.patid = d.patid |
| | | -- a.patid = b.patid and b.tagid = c.tagid and a.patid = d.patid |
| | | a.patid = d.patid |
| | | <if test="name != null and name != ''">and a.name like concat('%', #{name}, '%')</if> |
| | | <if test="idcardno != null and idcardno != ''">and a.idcardno = #{idcardno}</if> |
| | | <if test="pid != null and pid != ''">and a.patid = #{pid}</if> |
| | | <if test="telcode != null and telcode != ''">and a.telcode = #{telcode}</if> |
| | | <if test="tagIds != null and tagIds != ''">and c.tagid in |
| | | <foreach collection="tagIds" item="tagId" open="(" separator="," close=")"> |
| | | #{tagId} |
| | | </foreach> |
| | | </if> |
| | | <!-- <if test="tagIds != null and tagIds != ''">and c.tagid in--> |
| | | <!-- <foreach collection="tagIds" item="tagId" open="(" separator="," close=")">--> |
| | | <!-- #{tagId}--> |
| | | <!-- </foreach>--> |
| | | <!-- </if>--> |
| | | |
| | | <if test="hospitalname != null and hospitalname != ''"> |
| | | AND d.hospitalname = #{hospitalname} |
| | | </if> |
| | | <if test="hospitaldistrictname != null and hospitaldistrictname != ''"> |
| | | AND d.hospitaldistrictname LIKE concat('%',#{hospitaldistrictname}, '%') |
| | | </if> |
| | | <if test="leaveicd10code != null and leaveicd10code != ''"> |
| | | AND d.leaveicd10code LIKE concat('%',#{leaveicd10code}, '%') |
| | | </if> |
| | | <if test="endtime != null"> |
| | | AND d.endtime = #{endtime} |
| | |
| | | <if test="drname != null and drname != ''"> |
| | | AND d.drname LIKE concat('%',#{drname}, '%') |
| | | </if> |
| | | <if test="diagname != null and diagname != ''"> |
| | | AND d.diagname LIKE concat('%',#{diagname}, '%') |
| | | </if> |
| | | <if test="deptname != null and deptname != ''"> |
| | | AND d.deptname LIKE concat('%',#{deptname}, '%') |
| | | </if> |
| | | |
| | | AND d.del_flag != 1 |
| | | AND b.del_flag != 1 |
| | | AND c.del_flag != 1 |
| | | -- AND b.del_flag != 1 |
| | | -- AND c.del_flag != 1 |
| | | AND a.del_flag != 1 |
| | | </where> |
| | | </select> |
| | |
| | | resultMap="PatArchiveResult"> |
| | | |
| | | select |
| | | c.tagname as tag, |
| | | b.tagid as tagid, |
| | | -- c.tagname as tag, |
| | | -- b.tagid as tagid, |
| | | a.patid, |
| | | d.deptname, |
| | | a.name, |
| | |
| | | a.isupload, |
| | | a.upload_time, |
| | | a.pattype |
| | | from pat_archive a,pat_archivetag b ,base_tag c, pat_med_outhosp d |
| | | -- from pat_archive a,pat_archivetag b ,base_tag c, pat_med_outhosp d |
| | | from pat_archive a, pat_med_outhosp d |
| | | <where> |
| | | a.patid = b.patid and b.tagid = c.tagid and a.patid = d.patid |
| | | a.patid = d.patid |
| | | <if test="pid != null and pid != ''">and a.patid = #{pid}</if> |
| | | <if test="name != null and name != ''">and a.name like concat('%', #{name}, '%')</if> |
| | | <if test="idcardno != null and idcardno != ''">and a.idcardno = #{idcardno}</if> |
| | | <if test="telcode != null and telcode != ''">and a.telcode = #{telcode}</if> |
| | | <if test="tagIds != null and tagIds != ''">and c.tagid in |
| | | <foreach collection="tagIds" item="tagId" open="(" separator="," close=")"> |
| | | #{tagId} |
| | | </foreach> |
| | | <!-- <if test="tagIds != null and tagIds != ''">and c.tagid in--> |
| | | <!-- <foreach collection="tagIds" item="tagId" open="(" separator="," close=")">--> |
| | | <!-- #{tagId}--> |
| | | <!-- </foreach>--> |
| | | <!-- </if>--> |
| | | <if test="hospitaldistrictname != null and hospitaldistrictname != ''"> |
| | | AND d.hospitaldistrictname LIKE concat('%',#{hospitaldistrictname}, '%') |
| | | </if> |
| | | |
| | | <if test="diagname != null and diagname != ''"> |
| | | AND d.diagname LIKE concat('%',#{diagname}, '%') |
| | | </if> |
| | | <if test="hospitalname != null and hospitalname != ''"> |
| | | AND d.hospitalname = #{hospitalname} |
| | | </if> |
| | |
| | | </if> |
| | | |
| | | AND d.del_flag != 1 |
| | | AND b.del_flag != 1 |
| | | AND c.del_flag != 1 |
| | | -- AND b.del_flag != 1 |
| | | -- AND c.del_flag != 1 |
| | | AND a.del_flag != 1 |
| | | </where> |
| | | </select> |
| | |
| | | resultMap="PatArchiveResult"> |
| | | |
| | | select |
| | | c.tagname as tag, |
| | | b.tagid as tagid, |
| | | -- c.tagname as tag, |
| | | -- b.tagid as tagid, |
| | | a.patid as id, |
| | | a.name, |
| | | a.sex, |
| | |
| | | a.isupload, |
| | | a.upload_time, |
| | | a.pattype |
| | | from pat_archive a,pat_archivetag b ,base_tag c, pat_med_physical d |
| | | -- from pat_archive a,pat_archivetag b ,base_tag c, pat_med_physical d |
| | | from pat_archive a, pat_med_physical d |
| | | <where> |
| | | a.patid = b.patid and b.tagid = c.tagid and a.patid = d.patid |
| | | a.patid = d.patid |
| | | <if test="pid != null and pid != ''">and a.patid = #{pid}</if> |
| | | <if test="name != null and name != ''">and a.name like concat('%', #{name}, '%')</if> |
| | | <if test="idcardno != null and idcardno != ''">and a.idcardno = #{idcardno}</if> |
| | | <if test="telcode != null and telcode != ''">and a.telcode = #{telcode}</if> |
| | | <if test="tagIds != null and tagIds != ''">and c.tagid in |
| | | <foreach collection="tagIds" item="tagId" open="(" separator="," close=")"> |
| | | #{tagId} |
| | | </foreach> |
| | | <!-- <if test="tagIds != null and tagIds != ''">and c.tagid in--> |
| | | <!-- <foreach collection="tagIds" item="tagId" open="(" separator="," close=")">--> |
| | | <!-- #{tagId}--> |
| | | <!-- </foreach>--> |
| | | <!-- </if>--> |
| | | <if test="hospitaldistrictname != null and hospitaldistrictname != ''"> |
| | | AND d.hospitaldistrictname LIKE concat('%',#{hospitaldistrictname}, '%') |
| | | </if> |
| | | |
| | | <if test="diagname != null and diagname != ''"> |
| | | AND d.diagname LIKE concat('%',#{diagname}, '%') |
| | | </if> |
| | | <if test="hospitalname != null and hospitalname != ''"> |
| | | AND d.hospitalname = #{hospitalname} |
| | | </if> |
| | |
| | | </if> |
| | | |
| | | AND d.del_flag != 1 |
| | | AND b.del_flag != 1 |
| | | AND c.del_flag != 1 |
| | | -- AND b.del_flag != 1 |
| | | -- AND c.del_flag != 1 |
| | | AND a.del_flag != 1 |
| | | </where> |
| | | |
| | | </select> |
| | | |
| | | </mapper> |
| | | </mapper> |