zoukankan      html  css  js  c++  java
  • ssm+activiti+maven

    1spring整合activiti中添加activiti依赖

        <!-- 添加Activiti支持 -->
         <dependency>
            <groupId>org.activiti</groupId>
            <artifactId>activiti-engine</artifactId>
            <version>5.19.0.2</version>
        </dependency>
         
        <dependency>
            <groupId>org.activiti</groupId>
            <artifactId>activiti-spring</artifactId>
            <version>5.19.0.2</version>
        </dependency>
         
        <dependency>
            <groupId>org.activiti</groupId>
            <artifactId>activiti-bpmn-model</artifactId>
            <version>5.19.0.2</version>
        </dependency>
        <!-- spring整合activiti插件 -->
        <dependency>
            <groupId>org.activiti</groupId>
            <artifactId>activiti-spring</artifactId>
            <version>5.19.0.3</version>
        </dependency>

    添加activiti配置文件sring-activiti.xml

    <?xml version="1.0" encoding="UTF-8"?>
    <beans xmlns="http://www.springframework.org/schema/beans"
           xmlns:context="http://www.springframework.org/schema/context"
           xmlns:tx="http://www.springframework.org/schema/tx"
           xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
           xsi:schemaLocation="http://www.springframework.org/schema/beans   http://www.springframework.org/schema/beans/spring-beans.xsd
                               http://www.springframework.org/schema/context http://www.springframework.org/schema/context/spring-context-2.5.xsd
                               http://www.springframework.org/schema/tx      http://www.springframework.org/schema/tx/spring-tx-3.0.xsd">
      
     
      
      <!-- 定义流程引擎配置 -->
      <bean id="processEngineConfiguration" class="org.activiti.spring.SpringProcessEngineConfiguration">
        <property name="dataSource" ref="dataSource" />
        <property name="transactionManager" ref="transactionManager" />
        <property name="databaseSchemaUpdate" value="true" />
        <property name="jobExecutorActivate" value="false" />
      </bean>
      
      <!-- 定义流程引擎 -->
      <bean id="processEngine" class="org.activiti.spring.ProcessEngineFactoryBean">
        <property name="processEngineConfiguration" ref="processEngineConfiguration" />
      </bean>
      
      <!-- 定义Service服务 -->
      <bean id="repositoryService" factory-bean="processEngine" factory-method="getRepositoryService" />
      <bean id="runtimeService" factory-bean="processEngine" factory-method="getRuntimeService" />
      <bean id="taskService" factory-bean="processEngine" factory-method="getTaskService" />
      <bean id="historyService" factory-bean="processEngine" factory-method="getHistoryService" />
      <bean id="managementService" factory-bean="processEngine" factory-method="getManagementService" />
      <bean id="identityService" factory-bean="processEngine" factory-method="getIdentityService"/>
      <bean id="formService" factory-bean="processEngine" factory-method="getFormService"></bean>
     
    </beans>

    2 绘制流程图

    3

  • 相关阅读:
    初学网络编程
    Python模块(三)(正则,re,模块与包)
    Python模块(二)(序列化)
    idea2020.2安装与破解
    部署-jenkins发布项目到linux环境
    部署-jenkins发布项目到windows环境
    部署-jenkins与gitlab结合使用
    部署-docker推送镜像到远程仓库
    部署-gitlab克隆地址踩坑
    部署-docker安装jenkins
  • 原文地址:https://www.cnblogs.com/miye/p/7307174.html
Copyright © 2011-2022 走看看