| | |
| | | tid = Long.valueOf(serviceSubTaskCacheReq.getParam1()); |
| | | pid = Long.valueOf(serviceSubTaskCacheReq.getParam2()); |
| | | } |
| | | if (serviceSubTaskCacheReq.getType() != null && serviceSubTaskCacheReq.getType() == 2) { |
| | | if (CollectionUtils.isNotEmpty(serviceSubTaskCacheReq.getSvyLibTemplateScriptVOS()) && serviceSubTaskCacheReq.getSvyLibTemplateScriptVOS().size() > 0) { |
| | | //问卷 |
| | | redisCache.deleteObject(pid + "-" + tid + "-WJscriptCache"); |
| | | redisCache.setCacheListRight(pid + "-" + tid + "-WJscriptCache", serviceSubTaskCacheReq.getSvyLibTemplateScriptVOS()); |
| | |
| | | Long tims = Long.valueOf(3 * 24 * 3600); |
| | | boolean expire = redisCache.expire(pid + "-" + tid + "-WJscriptCache", tims); |
| | | return 1; |
| | | } else if (serviceSubTaskCacheReq.getType() != null && serviceSubTaskCacheReq.getType() == 1) { |
| | | } else if (CollectionUtils.isNotEmpty(serviceSubTaskCacheReq.getIvrLibaTemplateScriptVOList()) && serviceSubTaskCacheReq.getIvrLibaTemplateScriptVOList().size() > 0) { |
| | | //问卷 |
| | | redisCache.deleteObject(pid + "-" + tid + "-SFscriptCache"); |
| | | redisCache.setCacheListRight(pid + "-" + tid + "-SFscriptCache", serviceSubTaskCacheReq.getIvrLibaTemplateScriptVOList()); |
| | |
| | | if (StringUtils.isNotEmpty(scriptResult.get("asrtext"))) |
| | | svyLibTemplateScriptVO.setScriptResult(StringUtils.isNotEmpty(scriptResult.get("asrtext")) ? scriptResult.get("asrtext").replaceAll("^(\"|')(.*)\\1$", "$2") : ""); |
| | | svyLibTemplateScriptVO.setScriptResultId(scriptResult.get("asrtextId")); |
| | | if (StringUtils.isNotEmpty(scriptResult.get("answerps"))) |
| | | svyLibTemplateScriptVO.setAnswerps(scriptResult.get("answerps")); |
| | | } |
| | | } |
| | | map.put("scriptResult", svyLibTemplateScriptVOList); |
| | |
| | | if (CollectionUtils.isNotEmpty(serviceSubtaskDetails)) { |
| | | map.put("asrtext", serviceSubtaskDetails.get(0).getAsrtext()); |
| | | map.put("asrtextId", serviceSubtaskDetails.get(0).getId()); |
| | | map.put("answerps", serviceSubtaskDetails.get(0).getAnswerps()); |
| | | return map; |
| | | } |
| | | return null; |