fix: 修复定时任务启动没有传任务上下文
This commit is contained in:
@@ -2,6 +2,7 @@ package com.lanyuanxiaoyao.leopard.server.service;
|
||||
|
||||
import cn.hutool.core.util.IdUtil;
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import com.lanyuanxiaoyao.leopard.server.service.task.TaskMonitorNodes;
|
||||
import com.yomahub.liteflow.core.FlowExecutor;
|
||||
import java.time.LocalDateTime;
|
||||
import java.time.ZoneId;
|
||||
@@ -95,7 +96,8 @@ public class QuartzService {
|
||||
if (ObjectUtil.isNotNull(templateId)) {
|
||||
var template = taskTemplateService.detail(templateId);
|
||||
var params = (Map<String, Object>) dataMap.getOrDefault("params", Map.of());
|
||||
flowExecutor.execute2Resp(template.getChain(), params, context);
|
||||
var monitorContext = new TaskMonitorNodes.TaskMonitorContext(template);
|
||||
flowExecutor.execute2Resp(template.getChain(), params, monitorContext);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user