| | |
| | | import com.ruoyi.common.utils.poi.ExcelUtil; |
| | | import com.smartor.domain.ServiceSubTaskAnswerReq; |
| | | import com.smartor.domain.ServiceSubTaskCacheReq; |
| | | import com.smartor.domain.ServiceSubTaskDetailReq; |
| | | import com.smartor.domain.ServiceSubtaskAnswer; |
| | | import com.smartor.service.IServiceSubtaskAnswerService; |
| | | import io.swagger.annotations.Api; |
| | |
| | | # password: 123456 |
| | | |
| | | # 公司 |
| | | url: jdbc:mysql://116.62.18.175:6002/smartor?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8 |
| | | username: hxsoft |
| | | password: Hxerp2000 |
| | | url: jdbc:mysql://192.168.1.16:3308/smartor?useUnicode=true&characterEncoding=utf8&zeroDateTimeBehavior=convertToNull&useSSL=true&serverTimezone=GMT%2B8 |
| | | username: smartor |
| | | password: Smartor.2023 |
| | | driverClassName: com.mysql.cj.jdbc.Driver |
| | | # 从库数据源 |
| | | slave: |
| | |
| | | * @author ls |
| | | * @date 2023-06-05 |
| | | */ |
| | | @ApiModel(value = "ServiceSubTaskDetailReq", description = "问题回答明细") |
| | | @ApiModel(value = "ServiceSubTaskAnswerReq", description = "问题回答明细") |
| | | @Data |
| | | public class ServiceSubTaskAnswerReq { |
| | | |
| | |
| | | * @author ls |
| | | * @date 2023-06-05 |
| | | */ |
| | | @ApiModel(value = "ServiceSubTaskDetailReq", description = "问题回答明细") |
| | | @ApiModel(value = "ServiceSubTaskCacheReq", description = "问题回答明细") |
| | | @Data |
| | | public class ServiceSubTaskCacheReq { |
| | | |
| | |
| | | @ApiModelProperty(value = "患者ID") |
| | | private String param2; |
| | | |
| | | @ApiModelProperty(value = "问题回答明细") |
| | | @ApiModelProperty(value = "问题回答明细(随访)") |
| | | private List<IvrLibaTemplateScriptVO> ivrLibaTemplateScriptVOList; |
| | | |
| | | @ApiModelProperty(value = "问题回答明细") |
| | | @ApiModelProperty(value = "问题回答明细(问卷)") |
| | | List<SvyLibTemplateScriptVO> svyLibTemplateScriptVOList; |
| | | |
| | | } |
| | |
| | | RSAPublicKeyExample rsaPublicKeyExample = new RSAPublicKeyExample(); |
| | | Long tid = Long.valueOf(rsaPublicKeyExample.decryptedData(serviceSubTaskAnswerReq.getParam1(), pri_key)); |
| | | Long pid = Long.valueOf(rsaPublicKeyExample.decryptedData(serviceSubTaskAnswerReq.getParam2(), pri_key)); |
| | | |
| | | allKeys = new HashSet<>(); |
| | | if (serviceSubTaskAnswerReq.getType() == 1) { |
| | | allKeys.add(redisCache.getCacheObject(pid + "-" + tid + "-SFscriptCache")); |
| | | // allKeys.add(redisCache.getCacheObject(pid + "-" + tid + "-SFscriptCache")); |
| | | allKeys.add(pid + "-" + tid + "-SFscriptCache"); |
| | | } else if (serviceSubTaskAnswerReq.getType() == 2) { |
| | | allKeys.add(redisCache.getCacheObject(pid + "-" + tid + "-WJscriptCache")); |
| | | // allKeys.add(redisCache.getCacheObject(pid + "-" + tid + "-WJscriptCache")); |
| | | allKeys.add(pid + "-" + tid + "-WJscriptCache"); |
| | | } |
| | | } |
| | | |
| | |
| | | String[] split = key.split("-"); |
| | | if (key.contains("-SFscriptCache")) { |
| | | //包含了,说明了是随访问题 |
| | | List<IvrLibaTemplateScriptVO> cacheList = redisCache.getCacheList(key); |
| | | List<IvrLibaTemplateScriptVO> cacheList = redisCache.getCacheObject(key); |
| | | for (int i = 0; i < cacheList.size(); i++) { |
| | | if (i == 0) { |
| | | // 说明是第一题 |
| | |
| | | private void setSFInfo(IvrLibaTemplateScriptVO ivrLibaTemplateScriptVO, Long taskid, Long patid) { |
| | | ServiceSubtaskAnswer serviceSubtaskAnswer = null; |
| | | String dx = ""; |
| | | if (ivrLibaTemplateScriptVO.getScriptType().equals("1") || ivrLibaTemplateScriptVO.getScriptType().equals("2")) { |
| | | if (StringUtils.isNotEmpty(ivrLibaTemplateScriptVO.getScriptType()) && ivrLibaTemplateScriptVO.getScriptType().equals("1") || StringUtils.isNotEmpty(ivrLibaTemplateScriptVO.getScriptType()) && ivrLibaTemplateScriptVO.getScriptType().equals("2")) { |
| | | //1、2为单选或多选 |
| | | for (IvrLibaTemplateTargetoption ivrLibaTemplateTargetoption : ivrLibaTemplateScriptVO.getIvrLibaScriptTargetoptionList()) { |
| | | //获取用户选中的选项号 |
| | |
| | | dx = ivrLibaTemplateScriptVO.getIvrLibaScriptTargetoptionList().get(0).getAppenddesc(); |
| | | } |
| | | } |
| | | serviceSubtaskAnswer.setTaskid(Long.valueOf(taskid)); |
| | | serviceSubtaskAnswer.setPatId(Long.valueOf(patid)); |
| | | serviceSubtaskAnswer.setTaskid(taskid); |
| | | serviceSubtaskAnswer.setPatId(patid); |
| | | serviceSubtaskAnswer.setScriptid(ivrLibaTemplateScriptVO.getId()); |
| | | serviceSubtaskAnswer.setScriptType(Long.valueOf(ivrLibaTemplateScriptVO.getScriptType())); |
| | | serviceSubtaskAnswer.setAnswer(dx.substring(1)); |
| | |
| | | </resultMap> |
| | | |
| | | <sql id="selectIvrTaskTemplateScriptVo"> |
| | | select ID, taskid,branch_flag,branch_nextscriptno, templateID, questionPoint, noMatchText, noMatchVoice, slienceText, slienceVoice, submoduleText, submoduleVoice, noClearlyText, noClearlyVoice, categoryName, targetOptions, language, playWavOnly, value_type, del_flag, update_by, update_time, create_by, create_time, isupload, upload_time, orgid, pid, guid, targettype, targetid, targetvalue, otherdata, is_must, question_result from ivr_task_template_script |
| | | select id, taskid,branch_flag,branch_nextscriptno, templateID, questionPoint, noMatchText, noMatchVoice, slienceText, slienceVoice, submoduleText, submoduleVoice, noClearlyText, noClearlyVoice, categoryName, targetOptions, language, playWavOnly, value_type, del_flag, update_by, update_time, create_by, create_time, isupload, upload_time, orgid, pid, guid, targettype, targetid, targetvalue, otherdata, is_must, question_result from ivr_task_template_script |
| | | </sql> |
| | | |
| | | <select id="selectIvrTaskTemplateScriptList" parameterType="com.smartor.domain.IvrTaskTemplateScript" resultMap="IvrTaskTemplateScriptResult"> |
| | |
| | | where id = #{id} |
| | | </select> |
| | | |
| | | <insert id="insertIvrTaskTemplateScript" parameterType="com.smartor.domain.IvrTaskTemplateScript" useGeneratedKeys="true" keyProperty="ID"> |
| | | <insert id="insertIvrTaskTemplateScript" parameterType="com.smartor.domain.IvrTaskTemplateScript" useGeneratedKeys="true" keyProperty="id"> |
| | | insert into ivr_task_template_script |
| | | <trim prefix="(" suffix=")" suffixOverrides=","> |
| | | <if test="taskid != null">taskid,</if> |
| | |
| | | b.icd10name |
| | | FROM |
| | | svy_lib_template a |
| | | JOIN (select outid,GROUP_CONCAT(icd10code) as icd10code,GROUP_CONCAT(icd10name) as icd10name from |
| | | LEFT JOIN (select outid,GROUP_CONCAT(icd10code) as icd10code,GROUP_CONCAT(icd10name) as icd10name from |
| | | icd10_association group by outid) b ON a.del_flag = 0 |
| | | AND a.svyid = b.outid |
| | | <where> |