专病路径修改

This commit is contained in:
zhangheng 2024-07-11 15:11:22 +08:00
parent 81ea62eb40
commit affaec809e
5 changed files with 24 additions and 42 deletions

View File

@ -55,19 +55,19 @@ public class SignPatientManageRouteNode extends BaseEntity {
@Excel(name = "管理路径节点时间,时间单位为:天")
private Integer routeNodeDay;
/** 任务类型电话外呼PHONE_OUTBOUND问卷量表QUESTIONNAIRE_SCALE宣教文章PROPAGANDA_ARTICLE文字提醒TEXT_REMIND人工随访ARTIFICIAL_FOLLOW_UP短信提醒SMS_REMIND */
@ApiModelProperty(value = "任务类型电话外呼PHONE_OUTBOUND问卷量表QUESTIONNAIRE_SCALE宣教文章PROPAGANDA_ARTICLE文字提醒TEXT_REMIND人工随访ARTIFICIAL_FOLLOW_UP短信提醒SMS_REMIND")
@Excel(name = "任务类型电话外呼PHONE_OUTBOUND问卷量表QUESTIONNAIRE_SCALE宣教文章PROPAGANDA_ARTICLE文字提醒TEXT_REMIND人工随访ARTIFICIAL_FOLLOW_UP短信提醒SMS_REMIND")
/** 任务类型(编号) */
@ApiModelProperty(value = "任务类型(编号)")
@Excel(name = "任务类型(编号)")
private String taskType;
/** 任务状态 */
@ApiModelProperty(value = "任务状态")
@Excel(name = "任务状态")
/** 任务状态编号 */
@ApiModelProperty(value = "任务状态编号")
@Excel(name = "任务状态编号")
private String taskStatus;
/** 任务细分 */
@ApiModelProperty(value = "任务细分")
@Excel(name = "任务细分")
/** 任务细分编号 */
@ApiModelProperty(value = "任务细分编号")
@Excel(name = "任务细分编号")
private String taskSubdivision;
/** 二级分类描述 */

View File

@ -6,13 +6,7 @@ import com.xinelu.common.constant.TaskContentConstants;
import com.xinelu.common.constant.TaskCreateTypeConstant;
import com.xinelu.common.constant.TemplateTypeConstants;
import com.xinelu.common.core.domain.AjaxResult;
import com.xinelu.common.enums.NodeExecuteStatusEnum;
import com.xinelu.common.enums.PhoneConnectStatusEnum;
import com.xinelu.common.enums.PhoneDialMethodEnum;
import com.xinelu.common.enums.PhoneMessageRemindEnum;
import com.xinelu.common.enums.RouteNodeNameEnum;
import com.xinelu.common.enums.TaskContentEnum;
import com.xinelu.common.enums.TaskCreateTypeEnum;
import com.xinelu.common.enums.*;
import com.xinelu.common.exception.ServiceException;
import com.xinelu.common.utils.AgeUtil;
import com.xinelu.common.utils.SecurityUtils;
@ -166,7 +160,7 @@ public class SignPatientManageRouteServiceImpl implements ISignPatientManageRout
// 新增节点表
List<SignPatientManageRouteNode> signPatientManageRouteNodes = new ArrayList<>();
for (SignPatientManageRouteNode routeNode : signPatientManageRoute.getRouteNodeList()) {
if (Objects.isNull(routeNode) || StringUtils.isBlank(routeNode.getTaskType()) || (" ").equals(routeNode.getTaskType()) || StringUtils.isBlank(routeNode.getRouteNodeName()) || Objects.isNull(routeNode.getRouteNodeDay())) {
if (Objects.isNull(routeNode) || StringUtils.isBlank(routeNode.getTaskNodeType()) || (" ").equals(routeNode.getTaskNodeType()) || StringUtils.isBlank(routeNode.getRouteNodeName()) || Objects.isNull(routeNode.getRouteNodeDay())) {
continue;
}
extracted(signPatientManageRoute, signPatientManageRouteNodes, routeNode);
@ -671,7 +665,7 @@ public class SignPatientManageRouteServiceImpl implements ISignPatientManageRout
*/
private void extracted(SignPatientManageRouteVO signPatientManageRoute, List<SignPatientManageRouteNode> signPatientManageRouteNodes, SignPatientManageRouteNode routeNode) {
SignPatientManageRouteNode signPatientManageRouteNode = new SignPatientManageRouteNode();
if (Objects.nonNull(routeNode) && TaskContentEnum.PHONE_OUTBOUND.getInfo().equals(routeNode.getTaskType())) {
if (Objects.nonNull(routeNode) && TaskNodeTypeEnum.PHONE_OUTBOUND.getInfo().equals(routeNode.getTaskNodeType())) {
signPatientManageRouteNode.setPhonePushSign(Objects.isNull(routeNode.getPhonePushSign()) ? null : routeNode.getPhonePushSign());
signPatientManageRouteNode.setPhoneId(Objects.isNull(routeNode.getPhoneId()) ? null : routeNode.getPhoneId());
signPatientManageRouteNode.setPhoneTemplateId(Objects.isNull(routeNode.getPhoneTemplateId()) ? null : routeNode.getPhoneTemplateId());
@ -682,15 +676,14 @@ public class SignPatientManageRouteServiceImpl implements ISignPatientManageRout
signPatientManageRouteNode.setPhoneMessageRemind(StringUtils.isBlank(routeNode.getPhoneMessageRemind()) ? null : routeNode.getPhoneMessageRemind());
signPatientManageRouteNode.setPhoneMessageTemplateId(Objects.isNull(routeNode.getPhoneMessageTemplateId()) ? null : routeNode.getPhoneMessageTemplateId());
signPatientManageRouteNode.setPhoneMessageTemplateName(StringUtils.isBlank(routeNode.getPhoneMessageTemplateName()) ? null : routeNode.getPhoneMessageTemplateName());
signPatientManageRouteNode.setQuestionInfoId(Objects.isNull(routeNode.getQuestionInfoId()) ? null : routeNode.getQuestionInfoId());
signPatientManageRouteNode.setQuestionnaireName(StringUtils.isBlank(routeNode.getQuestionnaireName()) ? null : routeNode.getQuestionnaireName());
signPatientManageRouteNode.setQuestionnaireContent(StringUtils.isBlank(routeNode.getQuestionnaireContent()) ? null : routeNode.getQuestionnaireContent());
signPatientManageRouteNode.setPhoneDialMethod(StringUtils.isBlank(routeNode.getPhoneDialMethod()) ? null : routeNode.getPhoneDialMethod());
}
if (Objects.nonNull(routeNode) && TaskContentEnum.QUESTIONNAIRE_SCALE.getInfo().equals(routeNode.getTaskType())) {
if (Objects.nonNull(routeNode) && TaskNodeTypeEnum.QUESTIONNAIRE_SCALE.getInfo().equals(routeNode.getTaskNodeType())) {
signPatientManageRouteNode.setQuestionInfoId(Objects.isNull(routeNode.getQuestionInfoId()) ? null : routeNode.getQuestionInfoId());
signPatientManageRouteNode.setQuestionnaireName(StringUtils.isBlank(routeNode.getQuestionnaireName()) ? null : routeNode.getQuestionnaireName());
signPatientManageRouteNode.setQuestionnaireContent(StringUtils.isBlank(routeNode.getQuestionnaireContent()) ? null : routeNode.getQuestionnaireContent());
signPatientManageRouteNode.setQuestionExpirationDate(Objects.isNull(routeNode.getQuestionExpirationDate()) ? null : routeNode.getQuestionExpirationDate());
signPatientManageRouteNode.setPhoneDialMethod(StringUtils.isBlank(routeNode.getPhoneDialMethod()) ? null : routeNode.getPhoneDialMethod());
}
if (Objects.nonNull(routeNode) && TaskContentEnum.PROPAGANDA_ARTICLE.getInfo().equals(routeNode.getTaskType())) {
signPatientManageRouteNode.setPropagandaInfoId(Objects.isNull(routeNode.getPropagandaInfoId()) ? null : routeNode.getPropagandaInfoId());
@ -700,12 +693,6 @@ public class SignPatientManageRouteServiceImpl implements ISignPatientManageRout
if (Objects.nonNull(routeNode) && TaskContentEnum.TEXT_REMIND.getInfo().equals(routeNode.getTaskType())) {
signPatientManageRouteNode.setTextRemindContent(StringUtils.isBlank(routeNode.getTextRemindContent()) ? null : routeNode.getTextRemindContent());
}
if (Objects.nonNull(routeNode) && TaskContentEnum.ARTIFICIAL_FOLLOW_UP.getInfo().equals(routeNode.getTaskType())) {
signPatientManageRouteNode.setPhoneDialMethod(PhoneDialMethodEnum.COMMON.getInfo());
signPatientManageRouteNode.setPhoneTemplateId(Objects.isNull(routeNode.getPhoneTemplateId()) ? null : routeNode.getPhoneTemplateId());
signPatientManageRouteNode.setPhoneNodeContent(StringUtils.isBlank(routeNode.getPhoneNodeContent()) ? null : routeNode.getPhoneNodeContent());
signPatientManageRouteNode.setPhoneTemplateName(StringUtils.isBlank(routeNode.getPhoneTemplateName()) ? null : routeNode.getPhoneTemplateName());
}
signPatientManageRouteNode.setMessagePushSign(Objects.isNull(routeNode.getMessagePushSign()) ? null : routeNode.getMessagePushSign());
signPatientManageRouteNode.setMessageTemplateId(Objects.isNull(routeNode.getMessageTemplateId()) ? null : routeNode.getMessageTemplateId());
signPatientManageRouteNode.setMessageTemplateName(StringUtils.isBlank(routeNode.getMessageTemplateName()) ? null : routeNode.getMessageTemplateName());

View File

@ -166,9 +166,6 @@ public class SpecialDiseaseNodeServiceImpl implements ISpecialDiseaseNodeService
}
diseaseNode.setRouteId(specialDiseaseRoute.getId());
diseaseNode.setRouteName(specialDiseaseNode.getRouteName());
if (Objects.isNull(diseaseNode.getPhonePushSign()) || diseaseNode.getPhonePushSign() == 0) {
diseaseNode.setTemplateType(diseaseNode.getTaskSubdivisiontemplateType());
}
diseaseNode.setUpdateTime(LocalDateTime.now());
diseaseNode.setUpdateBy(SecurityUtils.getUsername());
if (CollectionUtils.isNotEmpty(longs) && (i < longs.size()) && Objects.nonNull(longs.get(i))) {

View File

@ -323,16 +323,14 @@
spmrn.manage_route_name AS 'manageRouteName',
spmrn.route_node_name AS 'routeNodeName',
spmrn.route_node_day,
spmrn.task_type,
spmrn.task_node_type,
CASE
WHEN spmrn.task_type = 'PHONE_OUTBOUND' THEN spmrn.phone_template_name
WHEN spmrn.task_type = 'QUESTIONNAIRE_SCALE' THEN spmrn.questionnaire_name
WHEN spmrn.task_type = 'ARTIFICIAL_FOLLOW_UP' THEN spmrn.follow_template_name
WHEN spmrn.task_node_type = 'PHONE_OUTBOUND' THEN spmrn.phone_template_name
WHEN spmrn.task_node_type = 'QUESTIONNAIRE_SCALE' THEN spmrn.questionnaire_name
END AS 'templateName',
CASE
WHEN spmrn.task_type = 'PHONE_OUTBOUND' THEN spmrn.phone_id
WHEN spmrn.task_type = 'QUESTIONNAIRE_SCALE' THEN spmrn.question_info_id
WHEN spmrn.task_type = 'ARTIFICIAL_FOLLOW_UP' THEN spmrn.follow_template_id
WHEN spmrn.task_node_type = 'PHONE_OUTBOUND' THEN spmrn.phone_id
WHEN spmrn.task_node_type = 'QUESTIONNAIRE_SCALE' THEN spmrn.question_info_id
END AS 'templateId',
spmrn.phone_id,
spmrn.follow_template_id,
@ -345,9 +343,10 @@
LEFT JOIN patient_info pi ON spmr.patient_id = pi.id
LEFT JOIN patient_visit_record pvr ON pi.patient_visit_record_id = pvr.id
<where>
pi.del_flag = '0'
pi.del_flag = 0
AND spmrn.route_check_status = 'AGREE'
AND spmrn.task_type in ('PHONE_OUTBOUND','QUESTIONNAIRE_SCALE','ARTIFICIAL_FOLLOW_UP')
AND spmrn.task_node_type in ('PHONE_OUTBOUND','QUESTIONNAIRE_SCALE')
AND spmrn.phone_dial_method = 'COMMON'
<if test="patientName != null and patientName != ''">
AND pi.patient_name LIKE concat('%', #{patientName}, '%')
</if>

View File

@ -841,9 +841,8 @@
sdn.route_node_day,
sdn.task_type,
sdn.task_subdivision,
sdn.task_type,
sdn.task_subdivision,
sdn.task_status,
sdn.task_node_type,
sdn.second_classify_describe,
sdn.execution_time,
sdn.template_id,