注释
This commit is contained in:
parent
984eb00163
commit
503fdcdab1
@ -75,7 +75,7 @@ public class subscribeTaskServiceImpl implements SubscribeTaskService {
|
||||
List<PatientVO> patientVOList = new ArrayList<>();
|
||||
//发送消息到期节点id集合
|
||||
List<Long> expiredManageRouteNodeIds = new ArrayList<>();
|
||||
//开始遍历患者任务,组装数据
|
||||
//2.1 开始遍历患者任务,组装数据
|
||||
for (PatientVO signPatientManageRouteNode : signPatientManageRouteNodes) {
|
||||
//判断推送状态
|
||||
if (Objects.isNull(signPatientManageRouteNode.getAppletPushSign()) || signPatientManageRouteNode.getAppletPushSign() != 1) {
|
||||
@ -108,7 +108,7 @@ public class subscribeTaskServiceImpl implements SubscribeTaskService {
|
||||
patientVOList.add(signPatientManageRouteNode);
|
||||
}
|
||||
}
|
||||
//更改过期执行状态
|
||||
//2.2 对过期的任务,更改过期执行状态
|
||||
if (CollectionUtils.isNotEmpty(expiredManageRouteNodeIds)) {
|
||||
signPatientManageRouteNodeMapper.updateNodeExecuteStatusByIds(expiredManageRouteNodeIds, NodeExecuteStatusEnum.EXECUTED.getInfo(), NodeExecuteResultStatusEnum.EXPIRED.getInfo(), null, null);
|
||||
}
|
||||
@ -162,7 +162,7 @@ public class subscribeTaskServiceImpl implements SubscribeTaskService {
|
||||
if (CollectionUtils.isEmpty(patientVOList)) {
|
||||
return;
|
||||
}
|
||||
//2.2 节点推送数量
|
||||
//2.3 节点推送数量,用于判断失败次数,若达到最大值,则认为失败;
|
||||
List<Long> collect = patientVOList.stream().filter(Objects::nonNull).map(PatientVO::getSignPatientManageRouteNodeId)
|
||||
.filter(Objects::nonNull).distinct().collect(Collectors.toList());
|
||||
//RecordNum,manageRouteNodeId:任务ID,num:已推送次数
|
||||
@ -201,6 +201,7 @@ public class subscribeTaskServiceImpl implements SubscribeTaskService {
|
||||
subscribeMessageSendRecord.setAppletId(weChatAppletChatConfig.getAppletId());
|
||||
subscribeMessageSendRecord.setTemplateId(weChatAppletChatConfig.getHealthyPropagandaId());
|
||||
subscribeMessageSendRecord.setCreateTime(LocalDateTime.now());
|
||||
//3.1 托送记录入库
|
||||
subscribeMessageSendRecordMapper.insertSubscribeMessageSendRecord(subscribeMessageSendRecord);
|
||||
}
|
||||
|
||||
|
||||
Loading…
Reference in New Issue
Block a user