liusheng
2024-07-22 1cff3842cca26d770bdba4f8fd2143742342b093
代码提交
已修改7个文件
36 ■■■■ 文件已修改
ruoyi-admin/src/main/java/com/ruoyi/web/controller/smartor/ServiceSubtaskAnswerController.java 1 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-admin/src/main/resources/application-druid.yml 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
smartor/src/main/java/com/smartor/domain/ServiceSubTaskAnswerReq.java 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
smartor/src/main/java/com/smartor/domain/ServiceSubTaskCacheReq.java 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
smartor/src/main/java/com/smartor/service/impl/ServiceSubtaskAnswerServiceImpl.java 15 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
smartor/src/main/resources/mapper/smartor/IvrTaskTemplateScriptMapper.xml 4 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
smartor/src/main/resources/mapper/smartor/SvyLibTemplateMapper.xml 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
ruoyi-admin/src/main/java/com/ruoyi/web/controller/smartor/ServiceSubtaskAnswerController.java
@@ -8,7 +8,6 @@
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;
ruoyi-admin/src/main/resources/application-druid.yml
@@ -12,9 +12,9 @@
        #        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:
smartor/src/main/java/com/smartor/domain/ServiceSubTaskAnswerReq.java
@@ -12,7 +12,7 @@
 * @author ls
 * @date 2023-06-05
 */
@ApiModel(value = "ServiceSubTaskDetailReq", description = "问题回答明细")
@ApiModel(value = "ServiceSubTaskAnswerReq", description = "问题回答明细")
@Data
public class ServiceSubTaskAnswerReq {
smartor/src/main/java/com/smartor/domain/ServiceSubTaskCacheReq.java
@@ -12,7 +12,7 @@
 * @author ls
 * @date 2023-06-05
 */
@ApiModel(value = "ServiceSubTaskDetailReq", description = "问题回答明细")
@ApiModel(value = "ServiceSubTaskCacheReq", description = "问题回答明细")
@Data
public class ServiceSubTaskCacheReq {
@@ -22,10 +22,10 @@
    @ApiModelProperty(value = "患者ID")
    private String param2;
    @ApiModelProperty(value = "问题回答明细")
    @ApiModelProperty(value = "问题回答明细(随访)")
    private List<IvrLibaTemplateScriptVO> ivrLibaTemplateScriptVOList;
    @ApiModelProperty(value = "问题回答明细")
    @ApiModelProperty(value = "问题回答明细(问卷)")
    List<SvyLibTemplateScriptVO> svyLibTemplateScriptVOList;
}
smartor/src/main/java/com/smartor/service/impl/ServiceSubtaskAnswerServiceImpl.java
@@ -117,11 +117,14 @@
            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");
            }
        }
@@ -130,7 +133,7 @@
            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) {
                        // 说明是第一题
@@ -199,7 +202,7 @@
    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()) {
                //获取用户选中的选项号
@@ -211,8 +214,8 @@
                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));
smartor/src/main/resources/mapper/smartor/IvrTaskTemplateScriptMapper.xml
@@ -43,7 +43,7 @@
    </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">
@@ -87,7 +87,7 @@
        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>
smartor/src/main/resources/mapper/smartor/SvyLibTemplateMapper.xml
@@ -108,7 +108,7 @@
        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>