package cn.axzo.workflow.core.converter.json;

import cn.axzo.workflow.common.model.request.bpmn.BpmnJsonNode;
import org.flowable.bpmn.model.Process;
import org.flowable.bpmn.model.ServiceTask;

/**
 * 服务任务节点
 *
 * @author wangli
 * @since 2023/10/17 15:47
 */
public class ServiceTaskJsonConverter extends AbstractBpmnJsonConverter<ServiceTask> {
    @Override
    public ServiceTask convertJsonToElement(BpmnJsonNode node, Process process) {
        ServiceTask serviceTask = new ServiceTask();
        serviceTask.setId(node.getId());
        serviceTask.setName(node.getName());
        return serviceTask;
    }
}
