songgaoshuai
2024-03-29 c859fa4c38cc027cb7005dcb5c504ffc89430e33
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
package org.dromara.workflow.listener;
 
import lombok.extern.slf4j.Slf4j;
import org.dromara.workflow.annotation.FlowListenerAnnotation;
import org.dromara.workflow.flowable.strategy.FlowTaskEventHandler;
import org.springframework.stereotype.Component;
 
/**
 * 自定义监听测试
 *
 * @author may
 * @date 2023-12-27
 */
@Slf4j
@Component
@FlowListenerAnnotation(processDefinitionKey = "leave1", taskDefId = "Activity_14633hx")
public class TestCustomTaskHandler implements FlowTaskEventHandler {
 
    @Override
    public void handleTask(String taskId, String businessKey) {
        log.info("任务ID:" + taskId + ",业务ID:" + businessKey);
    }
}