1.添加maven依赖
<!--审批流-->
<dependency>
<groupId>org.flowable</groupId>
<artifactId>flowable-spring-boot-starter-process</artifactId>
<version>6.5.0</version>
</dependency>
2.创建文件ProcessEngineConfig.java
注意文件存放路径和Application.java入口文件的相对位置,保证ProcessEngineConfig.java能正常注入。
文件内容如下:
package com.spt.config;
import org.flowable.engine.ProcessEngineConfiguration;
import org.flowable.spring.SpringProcessEngineConfiguration;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;
import org.springframework.jdbc.datasource.DataSourceTransactionManager;
import javax.sql.DataSource;
@Configuration
public class ProcessEngineConfig {
/**
* ProcessEngine 配置,其中DataSourceTra