Commit 0ef36470 authored by fangxinjiang's avatar fangxinjiang

定时任务 每5秒清理次 具体待办人待办提醒信息

parent eb3255a6
......@@ -26,17 +26,17 @@ public class MsgTask {
/**
* @Author fxj
* @Description 每29分钟刷新 超时待办提醒
* @Description 每1分钟刷新 超时待办提醒
* @Date 20:01 2023/5/30
* @Param
* @return
**/
public void createOderOverTimeMsg() {
log.info("-------------每29分钟刷新 超时待办提醒-定时任务开始------------");
log.info("-------------每1分钟刷新 超时待办提醒-定时任务开始------------");
HttpDaprUtil.invokeMethodPost(daprMsgProperties.getAppUrl(), daprMsgProperties.getAppId(),
"/msg/inner/updateOverTimeMsg", "", Object.class,
SecurityConstants.FROM_IN);
log.info("-------------每29分钟刷新 超时待办提醒定时任务结束------------");
log.info("-------------每1分钟刷新 超时待办提醒定时任务结束------------");
}
/**
......@@ -53,4 +53,20 @@ public class MsgTask {
SecurityConstants.FROM_IN);
log.info("-------------每29分钟刷新 薪资状态变更待支出提醒定时任务结束------------");
}
/**
* @Author fxj
* @Description 每5分钟刷新 超时待办提醒
* @Date 20:01 2023/5/30
* @Param
* @return
**/
public void cancelHandledMsg() {
log.info("-------------每5分钟刷新 更新待办任务-定时任务开始------------");
HttpDaprUtil.invokeMethodPost(daprMsgProperties.getAppUrl(), daprMsgProperties.getAppId(),
"/msg/inner/cancelHandledMsg", "", Object.class,
SecurityConstants.FROM_IN);
log.info("-------------每5分钟刷新 更新待办任务-定时任务结束------------");
}
}
\ No newline at end of file
......@@ -78,12 +78,12 @@ public class MsgInfoController {
/**
* @Author fxj
* @Description 每29分钟刷新 超时待办提醒
* @Description 每1分钟刷新 超时待办提醒
* @Date 20:05 2023/5/30
* @Param
* @return
**/
@Operation(summary = "每29分钟刷新 超时待办提醒", description = "每29分钟刷新 超时待办提醒")
@Operation(summary = "每1分钟刷新 超时待办提醒", description = "每1分钟刷新 超时待办提醒")
@Inner
@PostMapping("/inner/updateOverTimeMsg")
public void updateOverTimeMsg() {
......@@ -104,4 +104,18 @@ public class MsgInfoController {
public void statusChangeTimeMsg() {
msgInfoService.statusChangeTimeMsg();
}
/**
* @Author fxj
* @Description 每5秒 处理订单待办提醒
* @Date 15:58 2023/7/17
* @Param
* @return
**/
@Operation(summary = "每5秒 处理订单待办提醒", description = "每5秒 处理订单待办提醒")
@Inner
@PostMapping("/inner/cancelHandledMsg")
public void cancelHandledMsg() {
msgInfoService.cancelHandledMsg();
}
}
......@@ -49,4 +49,6 @@ public interface MsgInfoMapper extends BaseMapper<MsgInfo> {
List<MsgInfo> getMsgByTaskOne();
List<MsgInfo> getMsgInfo(@Param("msgInfo") MsgInfo msgInfo);
int deleteHandledMsg();
}
......@@ -46,4 +46,7 @@ public interface MsgInfoService extends IService<MsgInfo> {
void updateOverTimeMsg();
void statusChangeTimeMsg();
void cancelHandledMsg();
}
......@@ -215,4 +215,9 @@ public class MsgInfoServiceImpl extends ServiceImpl<MsgInfoMapper, MsgInfo> impl
}
}
@Override
public void cancelHandledMsg() {
baseMapper.deleteHandledMsg();
}
}
......@@ -147,4 +147,19 @@
b1.fd_3bddc3d6c8a734 = '待支出'
AND b1.fd_id IS NOT NULL
</select>
<delete id="deleteHandledMsg">
DELETE FROM msg_info where ALERT_TYPE ='0' and ORDER_NO not in (
SELECT
b1.fd_3ac901c5184274 ORDER_NO
FROM
lbpm_workitem a
LEFT JOIN lbpm_node e ON e.fd_id = a.fd_node_id
LEFT JOIN lbpm_process p ON p.fd_id = e.fd_process_id
LEFT JOIN ekp_ea33075576149bb8a4f5 b1 ON p.fd_model_id = b1.fd_id
WHERE
e.fd_fact_node_id = 'N5'
AND b1.fd_id IS NOT NULL
)
</delete>
</mapper>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment