在实际的开发当中,除了简单的业务逻辑之外,还有更为复杂的业务,例如常见的主从表单,总之采用Activiti的内置表单和外置表单方式无法满足所有的需求,这时,采用业务表单会更合适。业务表单模式非常灵活,最主要的特点就是讹误数据的存放不再存放在Activiti相关的数据表中,而是单独设计的业务数据表, 同时,将业务表单的主键存放在Activiti数据表中形成关联。
比如以之前的费用报销为例,进行业务表单的涉及。设计表如下所示
DROP TABLE IF EXISTS `Z_REIMBURSEMENT`;
CREATE TABLE `Z_REIMBURSEMENT` (
`ID` VARCHAR(64) NOT NULL ,
`PID` VARCHAR(64) NULL ,
`USERID` VARCHAR(64) NULL ,
`FEE` DECIMAL(10,2) NULL ,
`NOTE` VARCHAR(255) NULL ,
`FEEDATE` DATE NULL ,
`TYPE` VARCHAR(255) NULL ,
`BMYJ` VARCHAR(255) NULL ,
`REFEE` DECIMAL(10,2) NULL ,
`BZHU` VARCHAR(255) NULL ,
`CREATEDATETIME` DATETIME NULL ,
PRIMARY KEY (`ID`)
);
这个表有一个唯一主键ID标识记录的唯一性, 在实际业务中,必须将此字段和Activiti数据表ACT_RU_EXECUTION中的BUSINESS_KEY_
字段关联,这样在进行一个任务的时候,可以通过任务Id最后查出业务表单中的数据,如下面逻辑所示
// 获取任务Id查询任务
Task task = taskService.createTaskQuery().taskId(taskId).singleResult();
// 根据任务中流程实例主键获取任务对应的流程实例
String pId = task.getProcessInstanceId();
ProcessInstance pins = runtimeService.createProcessInstanceQuery()
.processInstanceId(pId)
.active().singleResult();
// 获取流程实例的业务主键 查询业务表单信息
String bId = pins.getBusinessKey();
actId = pins.getActivityId();
reimbursement = reimbursementService.selectByPrimaryKey(bId);
比如
而业务表单Z_REIMBURSEMENT中的第二个字段PID则记录的是流程实例的主键,这样就能保证业务表和运行中的流程实例意义对应了, 字段USERID用于记录流程开始人,其他字段的设计根据实际的业务来。由于表单数据都记录到业务表当中,所以流程定义就比较简单了。对应的文件名称为reimbursement-2.bpmn
。
<?xml version="1.0" encoding="UTF-8"?>
<definitions xmlns="http://www.omg.org/spec/BPMN/20100524/MODEL" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:activiti="http://activiti.org/bpmn" xmlns:bpmndi="http://www.omg.org/spec/BPMN/20100524/DI" xmlns:omgdc="http://www.omg.org/spec/DD/20100524/DC" xmlns:omgdi="http://www.omg.org/spec/DD/20100524/DI" typeLanguage="http://www.w3.org/2001/XMLSchema" expressionLanguage="http://www.w3.org/1999/XPath" targetNamespace="http://www.zioer.com/reimbursement-2">
<process id="reimbursement-2" name="费用报销-2" isExecutable="true">
<startEvent id="startevent1" name="Start" activiti:initiator="startUserId"></startEvent>
<userTask id="usertask1" name="部门领导审批" activiti:assignee="${startUserId}"></userTask>
<sequenceFlow id="flow1" sourceRef="startevent1" targetRef="usertask1"></sequenceFlow>
<userTask id="usertask2" name="财务部门审批" activiti:assignee="${startUserId}"></userTask>
<sequenceFlow id="flow2" sourceRef="usertask1" targetRef="usertask2"></sequenceFlow>
<userTask id="usertask3" name="申请人确认" activiti:assignee="${startUserId}"></userTask>
<sequenceFlow id="flow3" sourceRef="usertask2" targetRef="usertask3"></sequenceFlow>
<endEvent id="endevent1" name="End"></endEvent>
<sequenceFlow id="flow4" sourceRef="usertask3" targetRef="endevent1"></sequenceFlow>
</process>
<bpmndi:BPMNDiagram id="BPMNDiagram_reimbursement-2">
<bpmndi:BPMNPlane bpmnElement="reimbursement-2" id="BPMNPlane_reimbursement-2">
<bpmndi:BPMNShape bpmnElement="startevent1" id="BPMNShape_startevent1">
<omgdc:Bounds height="35.0" width="35.0" x="180.0" y="190.0"></omgdc:Bounds>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape bpmnElement="usertask1" id="BPMNShape_usertask1">
<omgdc:Bounds height="55.0" width="105.0" x="260.0" y="180.0"></omgdc:Bounds>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape bpmnElement="usertask2" id="BPMNShape_usertask2">
<omgdc:Bounds height="55.0" width="105.0" x="410.0" y="180.0"></omgdc:Bounds>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape bpmnElement="usertask3" id="BPMNShape_usertask3">
<omgdc:Bounds height="55.0" width="105.0" x="560.0" y="180.0"></omgdc:Bounds>
</bpmndi:BPMNShape>
<bpmndi:BPMNShape bpmnElement="endevent1" id="BPMNShape_endevent1">
<omgdc:Bounds height="35.0" width="35.0" x="710.0" y="190.0"></omgdc:Bounds>
</bpmndi:BPMNShape>
<bpmndi:BPMNEdge bpmnElement="flow1" id="BPMNEdge_flow1">
<omgdi:waypoint x="215.0" y="207.0"></omgdi:waypoint>
<omgdi:waypoint x="260.0" y="207.0"></omgdi:waypoint>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge bpmnElement="flow2" id="BPMNEdge_flow2">
<omgdi:waypoint x="365.0" y="207.0"></omgdi:waypoint>
<omgdi:waypoint x="410.0" y="207.0"></omgdi:waypoint>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge bpmnElement="flow3" id="BPMNEdge_flow3">
<omgdi:waypoint x="515.0" y="207.0"></omgdi:waypoint>
<omgdi:waypoint x="560.0" y="207.0"></omgdi:waypoint>
</bpmndi:BPMNEdge>
<bpmndi:BPMNEdge bpmnElement="flow4" id="BPMNEdge_flow4">
<omgdi:waypoint x="665.0" y="207.0"></omgdi:waypoint>
<omgdi:waypoint x="710.0" y="207.0"></omgdi:waypoint>
</bpmndi:BPMNEdge>
</bpmndi:BPMNPlane>
</bpmndi:BPMNDiagram>
</definitions>
为了测试方便,这里的ctiviti:assignee
都引用activiti:initiator
,也就是发起人就能经办所以的流程了。由于使用了业务表单,这里每个节点再也没有定义Form Key或Form的值了。因为业务表单不再需要这些,重点是需要关注的就是每个节点的id值,必须保证其在流程文件中的唯一性。设计好了之后,将改文件放到目录src/main/resources/processes/
当中,这样在程序启动的时候就能自动部署了,当然也可以采用手动部署的方式,这些在前面已经介绍过了。
由于要操作业务表单,所以必须在实体层、数据层和业务层添加类
实体层
package com.xquant.platform.test.activiti.entity;
import java.io.Serializable;
import java.util.Date;
import org.springframework.format.annotation.DateTimeFormat;
public class Reimbursement implements Serializable{
/**
*
*/
private static final long serialVersionUID = 1L;
private String id;
private String pid;
private String userId;
private double fee;
private String note;
@DateTimeFormat(pattern="yyyy-MM-dd")
private Date feedate;
private String type;
private String bmyj;
private double refee;
private String bzhu;
private Date createdatetime;
public String getId() {
return id;
}
public void setId(String id) {
this.id = id;
}
public String getPid() {
return pid;
}
public void setPid(String pid) {
this.pid = pid;
}
public String getUserId() {
return userId;
}
public void setUserId(String userId) {
this.userId = userId;
}
public double getFee() {
return fee;
}
public void setFee(double fee) {
this.fee = fee;
}
public String getNote() {
return note;
}
public void setNote(String note) {
this.note = note;
}
public Date getFeedate() {
return feedate;
}
public void setFeedate(Date feedate) {
this.feedate = feedate;
}
public String getType() {
return type;
}
public void setType(String type) {
this.type = type;
}
public String getBmyj() {
return bmyj;
}
public void setBmyj(String bmyj) {
this.bmyj = bmyj;
}
public double getRefee() {
return refee;
}
public void setRefee(double refee) {
this.refee = refee;
}
public String getBzhu() {
return bzhu;
}
public void setBzhu(String bzhu) {
this.bzhu = bzhu;
}
public Date getCreatedatetime() {
return createdatetime;
}
public void setCreatedatetime(Date createdatetime) {
this.createdatetime = createdatetime;
}
}
数据层
package com.xquant.platform.test.activiti.dao;
import com.xquant.platform.test.activiti.entity.Reimbursement;
import java.util.List;
public interface ReimbursementMapper {
public int insertReimbursement(Reimbursement record);
public int deleteBykey(String id);
public int updateReimbursement(Reimbursement record);
public List<Reimbursement> listAll();
public Reimbursement findByKey(String id);
}
对应的mapper定义src/main/resources/sqlmapper/ReimbursementMapper.xml
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.xquant.platform.test.activiti.dao.ReimbursementMapper">
<resultMap id="ReimbursementResultMap" type="com.xquant.platform.test.activiti.entity.Reimbursement" >
<id column="id" property="id" />
<result column="pid" property="pid" />
<result column="userId" property="userId" />
<result column="fee" property="fee" />
<result column="note" property="note" />
<result column="feedate" property="feedate" />
<result column="type" property="type" />
<result column="bmyj" property="bmyj" />
<result column="refee" property="refee" />
<result column="bzhu" property="bzhu" />
<result column="createdatetime" property="createdatetime" />
</resultMap>
<sql id="selectReimbursementColumn">
id,pid,userId,fee,note,
feedate,type,bmyj,refee,
bzhu,createdatetime
</sql>
<select id="findByKey" parameterType="String" resultMap="ReimbursementResultMap">
SELECT
<include refid="selectReimbursementColumn"></include>
from
Z_REIMBURSEMENT
where id = #{id}
</select>
<!-- 新增-->
<insert id="insertReimbursement" parameterType="com.xquant.platform.test.activiti.entity.Reimbursement">
<selectKey keyProperty="id" resultType="string" order="BEFORE">
SELECT REPLACE( UUID(),'-','') as a;
</selectKey>
INSERT INTO Z_REIMBURSEMENT
(id, pid, userId, fee, note, feedate,
type, bmyj, refee, bzhu, createdatetime)
VALUES
(
#{id},#{pid},#{userId},#{fee},
#{note},#{feedate},#{type},#{bmyj},
#{refee},#{bzhu},#{createdatetime}
)
</insert>
<!-- 删除-->
<delete id="deleteBykey" parameterType="String">
delete from Z_REIMBURSEMENT
where
id = #{id}
</delete>
<!-- 编辑-->
<update id="updateReimbursement" parameterType="com.xquant.platform.test.activiti.entity.Reimbursement">
update Z_REIMBURSEMENT
<set>
<if test="pid != null">
pid = #{pid},
</if>
<if test="userId != null">
userId = #{userId},
</if>
<if test="fee > 0">
fee = #{fee},
</if>
<if test="note != null">
note = #{note},
</if>
<if test="feedate != null">
feedate = #{feedate},
</if>
<if test="type != null">
type = #{type},
</if>
<if test="bmyj != null">
bmyj = #{bmyj},
</if>
<if test="refee > 0">
refee = #{refee},
</if>
<if test="bzhu != null">
bzhu = #{bzhu},
</if>
<if test="id != null">
id = #{id},
</if>
<if test="createdatetime != null">
createdatetime = #{createdatetime},
</if>
</set>
where id = #{id}
</update>
<!-- 列表(全部) -->
<select id="listAll" resultMap="ReimbursementResultMap" >
SELECT
<include refid="selectReimbursementColumn"></include>
from Z_REIMBURSEMENT
</select>
</mapper>
此处我们业务表单的唯一主键是随机生成的UUID值去掉中间的-后的字符串
业务层接口
package com.xquant.platform.test.activiti.service;
import com.xquant.platform.test.activiti.entity.Reimbursement;
import java.util.List;
public interface ReimbursementService {
int insert(Reimbursement record);
int deleteByPrimaryKey(String id);
int update(Reimbursement record);
Reimbursement selectByPrimaryKey(String id);
List<Reimbursement> listAll();
}
业务层实现类
package com.xquant.platform.test.activiti.service.Imp;
import com.xquant.platform.test.activiti.dao.ReimbursementMapper;
import com.xquant.platform.test.activiti.entity.Reimbursement;
import com.xquant.platform.test.activiti.service.ReimbursementService;
import org.activiti.engine.delegate.DelegateExecution;
import org.mybatis.spring.SqlSessionTemplate;
import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;
import javax.annotation.Resource;
import java.util.ArrayList;
import java.util.Date;
import java.util.List;
@Service
public class ReimbursementServiceImpl implements ReimbursementService {
@Resource(name = "sqlSessionTemplate")
private SqlSessionTemplate sqlSessionTemplate;
@Override
public int insert(Reimbursement record) {
ReimbursementMapper mapper = sqlSessionTemplate.getMapper(ReimbursementMapper.class);
return mapper.insertReimbursement(record);
}
@Override
public int deleteByPrimaryKey(String id) {
ReimbursementMapper mapper = sqlSessionTemplate.getMapper(ReimbursementMapper.class);
return mapper.deleteBykey(id);
}
@Override
public Reimbursement selectByPrimaryKey(String id) {
ReimbursementMapper mapper = sqlSessionTemplate.getMapper(ReimbursementMapper.class);
return mapper.findByKey(id);
}
@Override
public List<Reimbursement> listAll() {
ReimbursementMapper mapper = sqlSessionTemplate.getMapper(ReimbursementMapper.class);
List<Reimbursement> list = new ArrayList<Reimbursement>();
list = mapper.listAll();
return list;
}
@Override
public int update(Reimbursement record) {
ReimbursementMapper mapper = sqlSessionTemplate.getMapper(ReimbursementMapper.class);
return mapper.updateReimbursement(record);
}
@Transactional
public Reimbursement saveReimbursement(DelegateExecution execution){
String userId = execution.getVariable("startUserId").toString();
Reimbursement reimbursement = new Reimbursement();
reimbursement.setUserId(userId);
reimbursement.setCreatedatetime(new Date());
reimbursement.setPid(execution.getProcessInstanceId());
reimbursement.setFee(Integer.parseInt(execution.getVariable("fee").toString()));
reimbursement.setNote(execution.getVariable("note").toString());
reimbursement.setType(execution.getVariable("type").toString());
reimbursement.setFeedate((Date)execution.getVariable("feedate"));
insert(reimbursement);
return reimbursement;
}
@Transactional
public void updateReimbursement(DelegateExecution execution){
Reimbursement reimbursement = new Reimbursement();
reimbursement = (Reimbursement)execution.getVariable("var");
update(reimbursement);
return ;
}
}
另外我们修改了系统配置文件application.properties
中的相关配置,主要是关闭activiti的async任务,这样日志才更好看一些,要不然这个activiti.async任务会几秒钟执行一次,然后打印日志。
logging.level.org.activiti.engine=trace
spring.activiti.async-executor-enabled=false
spring.activiti.async-executor-activate=false
做好以上的工作之后,就可以添加一个控制层BussformController用于操作业务表单了。
package com.xquant.platform.test.activiti.controller;
import com.xquant.platform.test.activiti.entity.Reimbursement;
import com.xquant.platform.test.activiti.service.ReimbursementService;
import org.activiti.engine.*;
import org.activiti.engine.history.HistoricProcessInstance;
import org.activiti.engine.impl.persistence.entity.HistoricProcessInstanceEntity;
import org.activiti.engine.repository.ProcessDefinition;
import org.activiti.engine.runtime.ProcessInstance;
import org.activiti.engine.task.Task;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpSession;
import java.util.*;
/**
* 业务表单模式
*/
@Controller
@RequestMapping(value = "/bussform")
public class BussformController {
@Autowired
private RepositoryService repositoryService;
@Autowired
private FormService formService;
@Autowired
private TaskService taskService;
@Autowired
private IdentityService identityService;
@Autowired
private HistoryService historyService;
@Autowired
private RuntimeService runtimeService;
@Autowired
private ReimbursementService reimbursementService;
@RequestMapping(value = "/add")
public String add(Model model,HttpSession session) {
if (session.getAttribute("userId") == null){
return "redirect:/login/";
}
// 由于业务表单和流程逻辑无关,故其只是简单打开一个新增表单页面
return "reimbursement-2_start";
}
/**
* 提交启动流程
*/
@RequestMapping(value = "/start/save")
public String saveStartForm(Model model, Reimbursement reimbursement, HttpSession session) {
String userId = session.getAttribute("userId") == null ? null : session.getAttribute("userId").toString();
if (userId == null){
return "redirect:/login/";
}
Map<String, Object> variables = new HashMap<String, Object>();
// 首先保存业务数据
reimbursement.setUserId(userId);
reimbursement.setCreatedatetime(new Date());
reimbursementService.insert(reimbursement);
// 获取一个业务主键值
String businessKey = reimbursement.getId();
try{
ProcessDefinition processDefinition = repositoryService
.createProcessDefinitionQuery()
.processDefinitionKey("reimbursement-2")
.latestVersion().singleResult();
// 获取流程定义主键值
String processDefinitionId = processDefinition.getId();
ProcessInstance processInstance = null;
identityService.setAuthenticatedUserId(userId);
// 创建一个流程实例对象
processInstance = runtimeService.startProcessInstanceById(processDefinitionId, businessKey, variables);
// 在业务表单当中记录业务实例主键值
String pId = processInstance.getId();
reimbursement.setPid(pId);
reimbursementService.update(reimbursement);
} finally {
identityService.setAuthenticatedUserId(null);
}
return "redirect:/bussform/list";
}
@RequestMapping(value = "/list")
public String list(Model model,HttpSession session) {
String userId = session.getAttribute("userId") == null ? null : session.getAttribute("userId").toString();
if (userId == null){
return "redirect:/login/";
}
List<Task> tasks = new ArrayList<Task>();
//获得当前用户对应reimbursement-2流程的任务
tasks = taskService.createTaskQuery()
.taskCandidateOrAssigned(userId).processDefinitionKey("reimbursement-2")
.active()
.orderByTaskId().desc().list();
model.addAttribute("list", tasks);
return "reimbursement-2_list";
}
/**
* 初始化启动流程
*/
@RequestMapping(value = "/startform/{taskId}")
public String StartTaskForm(@PathVariable("taskId") String taskId,Model model,HttpSession session) throws Exception {
String userId = session.getAttribute("userId") == null ? null : session.getAttribute("userId").toString();
if (userId == null){
return "redirect:/login/";
}
Reimbursement reimbursement = null;
String actId = null;
try{
// 获取任务Id查询任务
Task task = taskService.createTaskQuery().taskId(taskId).singleResult();
// 根据任务中流程实例主键获取任务对应的流程实例
String pId = task.getProcessInstanceId();
ProcessInstance pins = runtimeService.createProcessInstanceQuery()
.processInstanceId(pId)
.active().singleResult();
// 获取流程实例的业务主键 查询业务表单信息
String bId = pins.getBusinessKey();
actId = pins.getActivityId();
reimbursement = reimbursementService.selectByPrimaryKey(bId);
}catch(Exception e){
}
model.addAttribute("data", reimbursement);
model.addAttribute("taskId", taskId);
model.addAttribute("actId", actId);
return "reimbursement-2_edit";
}
/**
* 提交启动流程
*/
@RequestMapping(value = "/startform/save/{taskId}")
public String saveTaskForm(@PathVariable("taskId") String taskId,HttpSession session,Reimbursement reimbursement) {
String userId = session.getAttribute("userId") == null ? null : session.getAttribute("userId").toString();
if (userId == null){
return "redirect:/login/";
}
try {
// 设置认证用户
identityService.setAuthenticatedUserId(userId);
Map<String, Object> map = new HashMap<String, Object>();
// 完成任务
taskService.complete(taskId, map);
// 保存业务表单信息
reimbursementService.update(reimbursement);
} finally {
identityService.setAuthenticatedUserId(null);
}
return "redirect:/bussform/list";
}
@RequestMapping(value = "/hlist")
public String historylist(Model model,HttpSession session) {
String userId = session.getAttribute("userId") == null ? null : session.getAttribute("userId").toString();
if (userId == null){
return "redirect:/login/";
}
List<Map> hlist = new ArrayList<Map>();
List historylist = historyService.createHistoricProcessInstanceQuery()
.processDefinitionKey("reimbursement-2")
.startedBy(userId).list();
for (int i=0;i<historylist.size();i++){
Map<String, Object> map = new HashMap<String, Object>();
HistoricProcessInstanceEntity hpe = (HistoricProcessInstanceEntity) historylist.get(i);
map.put("id", hpe.getId());
map.put("startUserId", hpe.getStartUserId());
map.put("processInstanceId", hpe.getProcessInstanceId());
map.put("endTime", hpe.getEndTime());
map.put("startTime", hpe.getStartTime());
if (hpe.getEndTime() == null){
Task task = taskService.createTaskQuery().processInstanceId(hpe.getProcessInstanceId()).active().singleResult();
if (task != null){
map.put("name", task.getName());
}
}else{
map.put("name", "已完成");
}
hlist.add(map);
}
//获得当前用户的任务
model.addAttribute("list", hlist);
return "reimbursement-2_hlist";
}
@RequestMapping(value = "/hview/{pId}")
public String historyView(@PathVariable("pId") String pId,Model model,HttpSession session) {
String userId = session.getAttribute("userId") == null ? null : session.getAttribute("userId").toString();
if (userId == null){
return "redirect:/login/";
}
String bId = null;
HistoricProcessInstance hpi = historyService.createHistoricProcessInstanceQuery()
.processInstanceId(pId)
.singleResult();
if (hpi != null){
bId = hpi.getBusinessKey();
}
Reimbursement reimbursement = reimbursementService.selectByPrimaryKey(bId);
model.addAttribute("data", reimbursement);
return "reimbursement2_hview";
}
public Map PageData(HttpServletRequest request){
Map properties = request.getParameterMap();
Map returnMap = new HashMap();
Iterator entries = properties.entrySet().iterator();
Map.Entry entry;
String name = "";
String value = "";
while (entries.hasNext()) {
entry = (Map.Entry) entries.next();
name = (String) entry.getKey();
Object valueObj = entry.getValue();
if(null == valueObj){
value = "";
}else if(valueObj instanceof String[]){
String[] values = (String[])valueObj;
for(int i=0;i<values.length;i++){
value = values[i] + ",";
}
value = value.substring(0, value.length()-1);
}else{
value = valueObj.toString();
}
returnMap.put(name, value);
}
return returnMap;
}
}
登录完成之后,首先访问地址http://localhost:8080/bussform/add
新增一个流程,此时的控制层逻辑其实很简单,返回一个reimbursement-2_start.jsp
页面即可、
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<html lang="en">
<head>
<title>费用报销-新增</title>
<link rel="stylesheet" rev="stylesheet" href="<%=basePath%>css/style.css" type="text/css" media="all" />
<script type="text/javascript" src="<%=basePath%>js/My97DatePicker/WdatePicker.js"></script>
<script language=JavaScript>
function save(){
document.getElementById("form").submit();
}
</script>
</head>
<body class="ContentBody">
<form action="start/save" method="post" name="form" id="form">
<div class="MainDiv">
<table width="90%" border="0" cellpadding="0" cellspacing="0" class="CContent">
<tr>
<th class="tablestyle_title" >费用报销(业务表单)-新增</th>
</tr>
<tr>
<td class="CPanel">
<table border="0" cellpadding="0" cellspacing="0" style="width:100%">
<TR>
<TD width="100%">
<fieldset style="height:100%;">
<legend>内容填写</legend>
<table border="0" cellpadding="2" cellspacing="1" style="width:100%">
<tr>
<td nowrap align="right" width="13%">费用</td>
<td width="19%"><input type='text' id='fee' name='fee' value='' /></td>
<td width="13%" align="right" nowrap>费用类型</td>
<td width="55%"><select id="type" name="type">
<option value="差旅费">差旅费</option>
<option value="书报费">书报费</option>
<option value="会议费">会议费</option>
<option value="其他费">其他费</option>
</select></td>
</tr>
<tr>
<td nowrap align="right">发生日期</td>
<td colspan="3"><input type='text' id='feedate' name='feedate' value='' onClick="WdatePicker()"/></td>
</tr>
<tr>
<td nowrap align="right" width="13%">说明</td>
<td colspan="3"><textarea id='note' name='note' rows="5" cols="50"></textarea></td>
</tr>
</table>
</fieldset>
</TD>
</TR>
</TABLE>
</td>
</tr>
<tr>
<TD colspan="2" align="center" height="50px">
<input type="button" name="Submit" value="保存" class="button" onclick="save();"/>
<input type="button" name="Submit2" value="返回" class="button" onclick="window.history.go(-1);"/>
</TD>
</tr>
</table>
</div>
</form>
</body>
</html>
新增内容并提交
此过程就比较关键了。将业务表单数据与流程实例绑定。
控制台日志如下所示
2021-03-27 14:00:44.979 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:00:44.983 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor : --- starting ProcessDefinitionQueryImpl --------------------------------------------------------
2021-03-27 14:00:45.028 DEBUG 9300 --- [nio-8080-exec-2] tProcessDefinitionsByQueryCriteria_mysql : ==> Preparing: select distinct RES.* from ACT_RE_PROCDEF RES WHERE RES.KEY_ = ? and RES.VERSION_ = (select max(VERSION_) from ACT_RE_PROCDEF where KEY_ = RES.KEY_ and ( (TENANT_ID_ IS NOT NULL and TENANT_ID_ = RES.TENANT_ID_) or (TENANT_ID_ IS NULL and RES.TENANT_ID_ IS NULL) ) ) order by RES.ID_ asc LIMIT ? OFFSET ?
2021-03-27 14:00:45.030 DEBUG 9300 --- [nio-8080-exec-2] tProcessDefinitionsByQueryCriteria_mysql : ==> Parameters: reimbursement-2(String), 2147483647(Integer), 0(Integer)
2021-03-27 14:00:45.035 TRACE 9300 --- [nio-8080-exec-2] tProcessDefinitionsByQueryCriteria_mysql : <== Columns: ID_, REV_, CATEGORY_, NAME_, KEY_, VERSION_, DEPLOYMENT_ID_, RESOURCE_NAME_, DGRM_RESOURCE_NAME_, DESCRIPTION_, HAS_START_FORM_KEY_, HAS_GRAPHICAL_NOTATION_, SUSPENSION_STATE_, TENANT_ID_
2021-03-27 14:00:45.036 TRACE 9300 --- [nio-8080-exec-2] tProcessDefinitionsByQueryCriteria_mysql : <== Row: reimbursement-2:2:70011, 1, http://www.zioer.com/reimbursement-2, 费用报销-2, reimbursement-2, 2, 70001, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement-2.bpmn, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement-2.reimbursement-2.png, null, 0, 1, 1,
2021-03-27 14:00:45.042 DEBUG 9300 --- [nio-8080-exec-2] tProcessDefinitionsByQueryCriteria_mysql : <== Total: 1
2021-03-27 14:00:45.043 TRACE 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : loaded object 'ProcessDefinitionEntity[reimbursement-2:2:70011]' was not updated
2021-03-27 14:00:45.044 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : flush summary: 0 insert, 0 update, 0 delete.
2021-03-27 14:00:45.044 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : now executing flush...
2021-03-27 14:00:45.048 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor : --- ProcessDefinitionQueryImpl finished --------------------------------------------------------
2021-03-27 14:00:45.049 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:03:13.282 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:03:13.284 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor : --- starting StartProcessInstanceCmd --------------------------------------------------------
2021-03-27 14:03:13.356 DEBUG 9300 --- [nio-8080-exec-2] .a.e.i.p.e.P.selectProcessDefinitionById : ==> Preparing: select * from ACT_RE_PROCDEF where ID_ = ?
2021-03-27 14:03:13.359 DEBUG 9300 --- [nio-8080-exec-2] .a.e.i.p.e.P.selectProcessDefinitionById : ==> Parameters: reimbursement-2:2:70011(String)
2021-03-27 14:03:13.364 TRACE 9300 --- [nio-8080-exec-2] .a.e.i.p.e.P.selectProcessDefinitionById : <== Columns: ID_, REV_, CATEGORY_, NAME_, KEY_, VERSION_, DEPLOYMENT_ID_, RESOURCE_NAME_, DGRM_RESOURCE_NAME_, DESCRIPTION_, HAS_START_FORM_KEY_, HAS_GRAPHICAL_NOTATION_, SUSPENSION_STATE_, TENANT_ID_
2021-03-27 14:03:13.365 TRACE 9300 --- [nio-8080-exec-2] .a.e.i.p.e.P.selectProcessDefinitionById : <== Row: reimbursement-2:2:70011, 1, http://www.zioer.com/reimbursement-2, 费用报销-2, reimbursement-2, 2, 70001, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement-2.bpmn, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement-2.reimbursement-2.png, null, 0, 1, 1,
2021-03-27 14:03:13.370 DEBUG 9300 --- [nio-8080-exec-2] .a.e.i.p.e.P.selectProcessDefinitionById : <== Total: 1
2021-03-27 14:03:13.371 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.D.selectDeploymentById : ==> Preparing: select * from ACT_RE_DEPLOYMENT where ID_ = ?
2021-03-27 14:03:13.373 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.D.selectDeploymentById : ==> Parameters: 70001(String)
2021-03-27 14:03:13.376 TRACE 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.D.selectDeploymentById : <== Columns: ID_, NAME_, CATEGORY_, TENANT_ID_, DEPLOY_TIME_
2021-03-27 14:03:13.378 TRACE 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.D.selectDeploymentById : <== Row: 70001, SpringAutoDeployment, null, , 2021-03-27 13:15:12.153
2021-03-27 14:03:13.381 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.D.selectDeploymentById : <== Total: 1
2021-03-27 14:03:13.383 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.bpmn.deployer.BpmnDeployer : Processing deployment SpringAutoDeployment
2021-03-27 14:03:13.384 DEBUG 9300 --- [nio-8080-exec-2] .e.i.p.e.R.selectResourcesByDeploymentId : ==> Preparing: select * from ACT_GE_BYTEARRAY where DEPLOYMENT_ID_ = ? order by NAME_ asc
2021-03-27 14:03:13.385 DEBUG 9300 --- [nio-8080-exec-2] .e.i.p.e.R.selectResourcesByDeploymentId : ==> Parameters: 70001(String)
2021-03-27 14:03:13.390 TRACE 9300 --- [nio-8080-exec-2] .e.i.p.e.R.selectResourcesByDeploymentId : <== Columns: ID_, REV_, NAME_, DEPLOYMENT_ID_, BYTES_, GENERATED_
2021-03-27 14:03:13.391 TRACE 9300 --- [nio-8080-exec-2] .e.i.p.e.R.selectResourcesByDeploymentId : <== Row: 70002, 1, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\basic.bpmn20.xml, 70001, <<BLOB>>, 0
2021-03-27 14:03:13.393 TRACE 9300 --- [nio-8080-exec-2] .e.i.p.e.R.selectResourcesByDeploymentId : <== Row: 70003, 1, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\basic2.bpmn, 70001, <<BLOB>>, 0
2021-03-27 14:03:13.395 TRACE 9300 --- [nio-8080-exec-2] .e.i.p.e.R.selectResourcesByDeploymentId : <== Row: 70005, 1, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement-2.bpmn, 70001, <<BLOB>>, 0
2021-03-27 14:03:13.396 TRACE 9300 --- [nio-8080-exec-2] .e.i.p.e.R.selectResourcesByDeploymentId : <== Row: 70007, 1, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement-2.reimbursement-2.png, 70001, <<BLOB>>, 1
2021-03-27 14:03:13.398 TRACE 9300 --- [nio-8080-exec-2] .e.i.p.e.R.selectResourcesByDeploymentId : <== Row: 70004, 1, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement.bpmn, 70001, <<BLOB>>, 0
2021-03-27 14:03:13.399 TRACE 9300 --- [nio-8080-exec-2] .e.i.p.e.R.selectResourcesByDeploymentId : <== Row: 70006, 1, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement.reimbursement.png, 70001, <<BLOB>>, 1
2021-03-27 14:03:13.403 DEBUG 9300 --- [nio-8080-exec-2] .e.i.p.e.R.selectResourcesByDeploymentId : <== Total: 6
2021-03-27 14:03:13.404 INFO 9300 --- [nio-8080-exec-2] o.a.e.impl.bpmn.deployer.BpmnDeployer : Processing resource E:\20200702\xquant-platform-component-test-ext\target\classes\processes\basic.bpmn20.xml
2021-03-27 14:03:13.603 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.handler.ProcessParseHandler : Parsing process waiter
2021-03-27 14:03:13.605 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity service1
2021-03-27 14:03:13.617 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity start
2021-03-27 14:03:13.623 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity end
2021-03-27 14:03:13.626 INFO 9300 --- [nio-8080-exec-2] o.a.e.impl.bpmn.deployer.BpmnDeployer : Processing resource E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement-2.reimbursement-2.png
2021-03-27 14:03:13.627 INFO 9300 --- [nio-8080-exec-2] o.a.e.impl.bpmn.deployer.BpmnDeployer : Processing resource E:\20200702\xquant-platform-component-test-ext\target\classes\processes\basic2.bpmn
2021-03-27 14:03:13.635 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.handler.ProcessParseHandler : Parsing process waiter2
2021-03-27 14:03:13.636 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity service1
2021-03-27 14:03:13.636 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity start
2021-03-27 14:03:13.637 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity end
2021-03-27 14:03:13.638 INFO 9300 --- [nio-8080-exec-2] o.a.e.impl.bpmn.deployer.BpmnDeployer : Processing resource E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement.bpmn
2021-03-27 14:03:13.662 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.handler.ProcessParseHandler : Parsing process reimbursement
2021-03-27 14:03:13.662 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity departmentApprove
2021-03-27 14:03:13.697 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity reimburseApprove
2021-03-27 14:03:13.699 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity usertask1
2021-03-27 14:03:13.707 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity startevent1
2021-03-27 14:03:13.708 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity endevent2
2021-03-27 14:03:13.710 INFO 9300 --- [nio-8080-exec-2] o.a.e.impl.bpmn.deployer.BpmnDeployer : Processing resource E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement.reimbursement.png
2021-03-27 14:03:13.710 INFO 9300 --- [nio-8080-exec-2] o.a.e.impl.bpmn.deployer.BpmnDeployer : Processing resource E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement-2.bpmn
2021-03-27 14:03:13.726 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.handler.ProcessParseHandler : Parsing process reimbursement-2
2021-03-27 14:03:13.727 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity usertask1
2021-03-27 14:03:13.728 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity usertask2
2021-03-27 14:03:13.729 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity usertask3
2021-03-27 14:03:13.730 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity startevent1
2021-03-27 14:03:13.730 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.p.h.AbstractBpmnParseHandler : Parsing activity endevent1
2021-03-27 14:03:13.733 DEBUG 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : ==> Preparing: select * from ACT_RE_PROCDEF where DEPLOYMENT_ID_ = ? and KEY_ = ? and (TENANT_ID_ = '' or TENANT_ID_ is null)
2021-03-27 14:03:13.734 DEBUG 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : ==> Parameters: 70001(String), waiter(String)
2021-03-27 14:03:13.739 TRACE 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : <== Columns: ID_, REV_, CATEGORY_, NAME_, KEY_, VERSION_, DEPLOYMENT_ID_, RESOURCE_NAME_, DGRM_RESOURCE_NAME_, DESCRIPTION_, HAS_START_FORM_KEY_, HAS_GRAPHICAL_NOTATION_, SUSPENSION_STATE_, TENANT_ID_
2021-03-27 14:03:13.741 TRACE 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : <== Row: waiter:6:70008, 1, processDefinitions, null, waiter, 6, 70001, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\basic.bpmn20.xml, null, null, 0, 0, 1,
2021-03-27 14:03:13.746 DEBUG 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : <== Total: 1
2021-03-27 14:03:13.748 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:03:13.749 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor : --- starting GetProcessDefinitionInfoCmd --------------------------------------------------------
2021-03-27 14:03:13.750 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.i.CommandContextInterceptor : Valid context found. Reusing it for the current command 'org.activiti.engine.impl.cmd.GetProcessDefinitionInfoCmd'
2021-03-27 14:03:13.751 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor : --- GetProcessDefinitionInfoCmd finished --------------------------------------------------------
2021-03-27 14:03:13.751 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:03:13.753 DEBUG 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : ==> Preparing: select * from ACT_RE_PROCDEF where DEPLOYMENT_ID_ = ? and KEY_ = ? and (TENANT_ID_ = '' or TENANT_ID_ is null)
2021-03-27 14:03:13.758 DEBUG 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : ==> Parameters: 70001(String), waiter2(String)
2021-03-27 14:03:13.762 TRACE 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : <== Columns: ID_, REV_, CATEGORY_, NAME_, KEY_, VERSION_, DEPLOYMENT_ID_, RESOURCE_NAME_, DGRM_RESOURCE_NAME_, DESCRIPTION_, HAS_START_FORM_KEY_, HAS_GRAPHICAL_NOTATION_, SUSPENSION_STATE_, TENANT_ID_
2021-03-27 14:03:13.763 TRACE 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : <== Row: waiter2:6:70009, 1, processDefinitions, null, waiter2, 6, 70001, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\basic2.bpmn, null, null, 0, 0, 1,
2021-03-27 14:03:13.769 DEBUG 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : <== Total: 1
2021-03-27 14:03:13.770 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:03:13.770 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor : --- starting GetProcessDefinitionInfoCmd --------------------------------------------------------
2021-03-27 14:03:13.771 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.i.CommandContextInterceptor : Valid context found. Reusing it for the current command 'org.activiti.engine.impl.cmd.GetProcessDefinitionInfoCmd'
2021-03-27 14:03:13.772 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor : --- GetProcessDefinitionInfoCmd finished --------------------------------------------------------
2021-03-27 14:03:13.773 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:03:13.774 DEBUG 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : ==> Preparing: select * from ACT_RE_PROCDEF where DEPLOYMENT_ID_ = ? and KEY_ = ? and (TENANT_ID_ = '' or TENANT_ID_ is null)
2021-03-27 14:03:13.776 DEBUG 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : ==> Parameters: 70001(String), reimbursement(String)
2021-03-27 14:03:13.780 TRACE 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : <== Columns: ID_, REV_, CATEGORY_, NAME_, KEY_, VERSION_, DEPLOYMENT_ID_, RESOURCE_NAME_, DGRM_RESOURCE_NAME_, DESCRIPTION_, HAS_START_FORM_KEY_, HAS_GRAPHICAL_NOTATION_, SUSPENSION_STATE_, TENANT_ID_
2021-03-27 14:03:13.781 TRACE 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : <== Row: reimbursement:8:70010, 1, http://www.zioer.com/reimbursement, 费用报销, reimbursement, 8, 70001, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement.bpmn, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement.reimbursement.png, 公司费用报销简易流程, 0, 1, 1,
2021-03-27 14:03:13.790 DEBUG 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : <== Total: 1
2021-03-27 14:03:13.791 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:03:13.792 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor : --- starting GetProcessDefinitionInfoCmd --------------------------------------------------------
2021-03-27 14:03:13.792 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.i.CommandContextInterceptor : Valid context found. Reusing it for the current command 'org.activiti.engine.impl.cmd.GetProcessDefinitionInfoCmd'
2021-03-27 14:03:13.793 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor : --- GetProcessDefinitionInfoCmd finished --------------------------------------------------------
2021-03-27 14:03:13.794 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:03:13.795 DEBUG 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : ==> Preparing: select * from ACT_RE_PROCDEF where DEPLOYMENT_ID_ = ? and KEY_ = ? and (TENANT_ID_ = '' or TENANT_ID_ is null)
2021-03-27 14:03:13.796 DEBUG 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : ==> Parameters: 70001(String), reimbursement-2(String)
2021-03-27 14:03:13.801 TRACE 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : <== Columns: ID_, REV_, CATEGORY_, NAME_, KEY_, VERSION_, DEPLOYMENT_ID_, RESOURCE_NAME_, DGRM_RESOURCE_NAME_, DESCRIPTION_, HAS_START_FORM_KEY_, HAS_GRAPHICAL_NOTATION_, SUSPENSION_STATE_, TENANT_ID_
2021-03-27 14:03:13.802 TRACE 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : <== Row: reimbursement-2:2:70011, 1, http://www.zioer.com/reimbursement-2, 费用报销-2, reimbursement-2, 2, 70001, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement-2.bpmn, E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement-2.reimbursement-2.png, null, 0, 1, 1,
2021-03-27 14:03:13.807 DEBUG 9300 --- [nio-8080-exec-2] electProcessDefinitionByDeploymentAndKey : <== Total: 1
2021-03-27 14:03:13.808 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:03:13.809 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor : --- starting GetProcessDefinitionInfoCmd --------------------------------------------------------
2021-03-27 14:03:13.810 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.i.CommandContextInterceptor : Valid context found. Reusing it for the current command 'org.activiti.engine.impl.cmd.GetProcessDefinitionInfoCmd'
2021-03-27 14:03:13.810 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor : --- GetProcessDefinitionInfoCmd finished --------------------------------------------------------
2021-03-27 14:03:13.811 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:03:13.813 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:03:13.814 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor : --- starting GetNextIdBlockCmd --------------------------------------------------------
2021-03-27 14:03:13.827 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.P.selectProperty : ==> Preparing: select * from ACT_GE_PROPERTY where NAME_ = ?
2021-03-27 14:03:13.829 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.P.selectProperty : ==> Parameters: next.dbid(String)
2021-03-27 14:03:13.834 TRACE 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.P.selectProperty : <== Columns: NAME_, VALUE_, REV_
2021-03-27 14:03:13.835 TRACE 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.P.selectProperty : <== Row: next.dbid, 72501, 30
2021-03-27 14:03:13.836 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.P.selectProperty : <== Total: 1
2021-03-27 14:03:13.839 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : update PropertyEntity[name=next.dbid, value=75001]
2021-03-27 14:03:13.840 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : flush summary: 0 insert, 1 update, 0 delete.
2021-03-27 14:03:13.841 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : now executing flush...
2021-03-27 14:03:13.841 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : updating: PropertyEntity[name=next.dbid, value=75001]
2021-03-27 14:03:13.845 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.P.updateProperty : ==> Preparing: update ACT_GE_PROPERTY SET REV_ = ?, VALUE_ = ? where NAME_ = ? and REV_ = ?
2021-03-27 14:03:13.850 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.P.updateProperty : ==> Parameters: 31(Integer), 75001(String), next.dbid(String), 30(Integer)
2021-03-27 14:03:13.858 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.P.updateProperty : <== Updates: 1
2021-03-27 14:03:16.139 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor : --- GetNextIdBlockCmd finished --------------------------------------------------------
2021-03-27 14:03:16.139 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:03:16.140 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.entity.ExecutionEntity : initializing ProcessInstance[72501]
2021-03-27 14:03:16.144 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: ACTIVITY
2021-03-27 14:03:16.145 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: FULL
2021-03-27 14:03:16.149 DEBUG 9300 --- [nio-8080-exec-2] e.I.selectIdentityLinksByProcessInstance : ==> Preparing: select * from ACT_RU_IDENTITYLINK where PROC_INST_ID_ = ?
2021-03-27 14:03:16.150 DEBUG 9300 --- [nio-8080-exec-2] e.I.selectIdentityLinksByProcessInstance : ==> Parameters: 72501(String)
2021-03-27 14:03:16.162 DEBUG 9300 --- [nio-8080-exec-2] e.I.selectIdentityLinksByProcessInstance : <== Total: 0
2021-03-27 14:03:16.169 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: AUDIT
2021-03-27 14:03:16.173 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: ACTIVITY
2021-03-27 14:03:16.202 TRACE 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationProcessStart@47407b6d on org.activiti.engine.impl.interceptor.CommandContext@72c5f7ef
2021-03-27 14:03:16.209 TRACE 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationProcessStartInitial@7ca2606c on org.activiti.engine.impl.interceptor.CommandContext@72c5f7ef
2021-03-27 14:03:16.210 TRACE 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationActivityExecute@5c870ea0 on org.activiti.engine.impl.interceptor.CommandContext@72c5f7ef
2021-03-27 14:03:16.211 DEBUG 9300 --- [nio-8080-exec-2] a.e.i.p.r.AtomicOperationActivityExecute : ProcessInstance[72501] executes Activity(startevent1): org.activiti.engine.impl.bpmn.behavior.NoneStartEventActivityBehavior
2021-03-27 14:03:16.218 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.J.selectJobsByExecutionId : ==> Preparing: select * from ACT_RU_JOB J where J.EXECUTION_ID_ = ?
2021-03-27 14:03:16.219 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.J.selectJobsByExecutionId : ==> Parameters: 72501(String)
2021-03-27 14:03:16.225 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.J.selectJobsByExecutionId : <== Total: 0
2021-03-27 14:03:16.226 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.b.behavior.BpmnActivityBehavior : Leaving activity 'startevent1'
2021-03-27 14:03:16.229 TRACE 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationTransitionNotifyListenerEnd@673caa1f on org.activiti.engine.impl.interceptor.CommandContext@72c5f7ef
2021-03-27 14:03:16.230 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: ACTIVITY
2021-03-27 14:03:16.231 TRACE 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationTransitionNotifyListenerEnd@673caa1f on org.activiti.engine.impl.interceptor.CommandContext@72c5f7ef
2021-03-27 14:03:16.232 TRACE 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationTransitionDestroyScope@30f8c7eb on org.activiti.engine.impl.interceptor.CommandContext@72c5f7ef
2021-03-27 14:03:16.232 TRACE 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationTransitionNotifyListenerTake@3a4ee6a3 on org.activiti.engine.impl.interceptor.CommandContext@72c5f7ef
2021-03-27 14:03:16.233 DEBUG 9300 --- [nio-8080-exec-2] micOperationTransitionNotifyListenerTake : ProcessInstance[72501] takes transition (startevent1)--flow1-->(usertask1)
2021-03-27 14:03:16.237 TRACE 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationTransitionCreateScope@26f1141f on org.activiti.engine.impl.interceptor.CommandContext@72c5f7ef
2021-03-27 14:03:16.238 TRACE 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationTransitionNotifyListenerStart@2e0c167b on org.activiti.engine.impl.interceptor.CommandContext@72c5f7ef
2021-03-27 14:03:16.239 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: ACTIVITY
2021-03-27 14:03:16.240 TRACE 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationTransitionNotifyListenerStart@2e0c167b on org.activiti.engine.impl.interceptor.CommandContext@72c5f7ef
2021-03-27 14:03:16.241 TRACE 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationActivityExecute@5c870ea0 on org.activiti.engine.impl.interceptor.CommandContext@72c5f7ef
2021-03-27 14:03:16.241 DEBUG 9300 --- [nio-8080-exec-2] a.e.i.p.r.AtomicOperationActivityExecute : ProcessInstance[72501] executes Activity(usertask1): org.activiti.engine.impl.bpmn.behavior.UserTaskActivityBehavior
2021-03-27 14:03:16.244 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.T.selectTasksByExecutionId : ==> Preparing: select distinct T.* from ACT_RU_TASK T where T.EXECUTION_ID_ = ?
2021-03-27 14:03:16.246 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.T.selectTasksByExecutionId : ==> Parameters: 72501(String)
2021-03-27 14:03:16.251 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.T.selectTasksByExecutionId : <== Total: 0
2021-03-27 14:03:16.252 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: AUDIT
2021-03-27 14:03:16.253 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: AUDIT
2021-03-27 14:03:16.254 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: AUDIT
2021-03-27 14:03:16.279 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: AUDIT
2021-03-27 14:03:16.280 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: AUDIT
2021-03-27 14:03:16.283 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: ACTIVITY
2021-03-27 14:03:16.284 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: ACTIVITY
2021-03-27 14:03:16.285 TRACE 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : loaded object 'DeploymentEntity[id=70001, name=SpringAutoDeployment]' was not updated
2021-03-27 14:03:16.286 TRACE 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : loaded object 'ProcessDefinitionEntity[reimbursement:8:70010]' was not updated
2021-03-27 14:03:16.287 TRACE 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : loaded object 'ProcessDefinitionEntity[waiter:6:70008]' was not updated
2021-03-27 14:03:16.288 TRACE 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : loaded object 'ProcessDefinitionEntity[reimbursement-2:2:70011]' was not updated
2021-03-27 14:03:16.288 TRACE 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : loaded object 'ProcessDefinitionEntity[waiter2:6:70009]' was not updated
2021-03-27 14:03:16.289 TRACE 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : loaded object 'ResourceEntity[id=70006, name=E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement.reimbursement.png]' was not updated
2021-03-27 14:03:16.289 TRACE 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : loaded object 'ResourceEntity[id=70005, name=E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement-2.bpmn]' was not updated
2021-03-27 14:03:16.290 TRACE 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : loaded object 'ResourceEntity[id=70007, name=E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement-2.reimbursement-2.png]' was not updated
2021-03-27 14:03:16.291 TRACE 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : loaded object 'ResourceEntity[id=70002, name=E:\20200702\xquant-platform-component-test-ext\target\classes\processes\basic.bpmn20.xml]' was not updated
2021-03-27 14:03:16.291 TRACE 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : loaded object 'ResourceEntity[id=70004, name=E:\20200702\xquant-platform-component-test-ext\target\classes\processes\reimbursement.bpmn]' was not updated
2021-03-27 14:03:16.292 TRACE 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : loaded object 'ResourceEntity[id=70003, name=E:\20200702\xquant-platform-component-test-ext\target\classes\processes\basic2.bpmn]' was not updated
2021-03-27 14:03:16.292 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : insert HistoricProcessInstanceEntity[superProcessInstanceId=null]
2021-03-27 14:03:16.293 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : insert HistoricActivityInstanceEntity[activityId=startevent1, activityName=Start]
2021-03-27 14:03:16.294 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : insert HistoricActivityInstanceEntity[activityId=usertask1, activityName=部门领导审批]
2021-03-27 14:03:16.295 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : insert org.activiti.engine.impl.persistence.entity.HistoricIdentityLinkEntity@739649d2
2021-03-27 14:03:16.295 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : insert HistoricVariableInstanceEntity[id=72502, name=startUserId, revision=0, type=string, textValue=admin]
2021-03-27 14:03:16.296 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : insert Task[id=72506, name=部门领导审批]
2021-03-27 14:03:16.297 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : insert VariableInstanceEntity[id=72502, name=startUserId, type=string, textValue=admin]
2021-03-27 14:03:16.297 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : insert ProcessInstance[72501]
2021-03-27 14:03:16.298 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : insert IdentityLinkEntity[id=72503, type=starter, userId=admin, processInstanceId=72501]
2021-03-27 14:03:16.299 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : insert HistoricTaskInstanceEntity[id=72506, name=部门领导审批]
2021-03-27 14:03:16.299 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : flush summary: 10 insert, 0 update, 0 delete.
2021-03-27 14:03:16.300 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : now executing flush...
2021-03-27 14:03:16.301 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : inserting: HistoricVariableInstanceEntity[id=72502, name=startUserId, revision=0, type=string, textValue=admin]
2021-03-27 14:03:16.302 DEBUG 9300 --- [nio-8080-exec-2] e.i.p.e.H.insertHistoricVariableInstance : ==> Preparing: insert into ACT_HI_VARINST (ID_, PROC_INST_ID_, EXECUTION_ID_, TASK_ID_, NAME_, REV_, VAR_TYPE_, BYTEARRAY_ID_, DOUBLE_, LONG_ , TEXT_, TEXT2_, CREATE_TIME_, LAST_UPDATED_TIME_) values ( ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? )
2021-03-27 14:03:16.316 DEBUG 9300 --- [nio-8080-exec-2] e.i.p.e.H.insertHistoricVariableInstance : ==> Parameters: 72502(String), 72501(String), 72501(String), null, startUserId(String), 0(Integer), string(String), null, null, null, admin(String), null, 2021-03-27 14:03:16.145(Timestamp), 2021-03-27 14:03:16.145(Timestamp)
2021-03-27 14:03:16.319 DEBUG 9300 --- [nio-8080-exec-2] e.i.p.e.H.insertHistoricVariableInstance : <== Updates: 1
2021-03-27 14:03:16.320 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : inserting: HistoricTaskInstanceEntity[id=72506, name=部门领导审批]
2021-03-27 14:03:16.322 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.H.insertHistoricTaskInstance : ==> Preparing: insert into ACT_HI_TASKINST ( ID_, PROC_DEF_ID_, PROC_INST_ID_, EXECUTION_ID_, NAME_, PARENT_TASK_ID_, DESCRIPTION_, OWNER_, ASSIGNEE_, START_TIME_, CLAIM_TIME_, END_TIME_, DURATION_, DELETE_REASON_, TASK_DEF_KEY_, FORM_KEY_, PRIORITY_, DUE_DATE_, CATEGORY_, TENANT_ID_ ) values ( ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? )
2021-03-27 14:03:16.351 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.H.insertHistoricTaskInstance : ==> Parameters: 72506(String), reimbursement-2:2:70011(String), 72501(String), 72501(String), 部门领导审批(String), null, null, null, admin(String), 2021-03-27 14:03:16.253(Timestamp), null, null, null, null, usertask1(String), null, 50(Integer), null, null, (String)
2021-03-27 14:03:16.354 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.H.insertHistoricTaskInstance : <== Updates: 1
2021-03-27 14:03:16.355 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : inserting: HistoricProcessInstanceEntity[superProcessInstanceId=null]
2021-03-27 14:03:16.357 DEBUG 9300 --- [nio-8080-exec-2] .e.i.p.e.H.insertHistoricProcessInstance : ==> Preparing: insert into ACT_HI_PROCINST ( ID_, PROC_INST_ID_, BUSINESS_KEY_, PROC_DEF_ID_, START_TIME_, END_TIME_, DURATION_, START_USER_ID_, START_ACT_ID_, END_ACT_ID_, SUPER_PROCESS_INSTANCE_ID_, DELETE_REASON_, TENANT_ID_, NAME_ ) values ( ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? )
2021-03-27 14:03:16.377 DEBUG 9300 --- [nio-8080-exec-2] .e.i.p.e.H.insertHistoricProcessInstance : ==> Parameters: 72501(String), 72501(String), b2e214608e6711eb857c0242ac110002(String), reimbursement-2:2:70011(String), 2021-03-27 14:03:16.174(Timestamp), null, null, admin(String), startevent1(String), null, null, null, (String), null
2021-03-27 14:03:16.380 DEBUG 9300 --- [nio-8080-exec-2] .e.i.p.e.H.insertHistoricProcessInstance : <== Updates: 1
2021-03-27 14:03:16.450 DEBUG 9300 --- [nio-8080-exec-2] p.e.H.bulkInsertHistoricActivityInstance : ==> Preparing: insert into ACT_HI_ACTINST ( ID_, PROC_DEF_ID_, PROC_INST_ID_, EXECUTION_ID_, ACT_ID_, TASK_ID_, CALL_PROC_INST_ID_, ACT_NAME_, ACT_TYPE_, ASSIGNEE_, START_TIME_, END_TIME_, DURATION_, TENANT_ID_ ) values (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?) , (?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?)
2021-03-27 14:03:16.483 DEBUG 9300 --- [nio-8080-exec-2] p.e.H.bulkInsertHistoricActivityInstance : ==> Parameters: 72504(String), reimbursement-2:2:70011(String), 72501(String), 72501(String), startevent1(String), null, null, Start(String), startEvent(String), null, 2021-03-27 14:03:16.174(Timestamp), 2021-03-27 14:03:16.231(Timestamp), 57(Long), (String), 72505(String), reimbursement-2:2:70011(String), 72501(String), 72501(String), usertask1(String), 72506(String), null, 部门领导审批(String), userTask(String), admin(String), 2021-03-27 14:03:16.24(Timestamp), null, null, (String)
2021-03-27 14:03:16.488 DEBUG 9300 --- [nio-8080-exec-2] p.e.H.bulkInsertHistoricActivityInstance : <== Updates: 2
2021-03-27 14:03:16.489 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : inserting: org.activiti.engine.impl.persistence.entity.HistoricIdentityLinkEntity@739649d2
2021-03-27 14:03:16.491 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.H.insertHistoricIdentityLink : ==> Preparing: insert into ACT_HI_IDENTITYLINK (ID_, TYPE_, USER_ID_, GROUP_ID_, TASK_ID_, PROC_INST_ID_) values (?, ?, ?, ?, ?, ?)
2021-03-27 14:03:16.499 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.H.insertHistoricIdentityLink : ==> Parameters: 72503(String), starter(String), admin(String), null, null, 72501(String)
2021-03-27 14:03:16.502 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.H.insertHistoricIdentityLink : <== Updates: 1
2021-03-27 14:03:16.504 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : inserting: ProcessInstance[72501]
2021-03-27 14:03:16.506 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.E.insertExecution : ==> Preparing: insert into ACT_RU_EXECUTION (ID_, REV_, PROC_INST_ID_, BUSINESS_KEY_, PROC_DEF_ID_, ACT_ID_, IS_ACTIVE_, IS_CONCURRENT_, IS_SCOPE_,IS_EVENT_SCOPE_, PARENT_ID_, SUPER_EXEC_, SUSPENSION_STATE_, CACHED_ENT_STATE_, TENANT_ID_, NAME_) values ( ?, 1, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? )
2021-03-27 14:03:16.527 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.E.insertExecution : ==> Parameters: 72501(String), 72501(String), b2e214608e6711eb857c0242ac110002(String), reimbursement-2:2:70011(String), usertask1(String), true(Boolean), false(Boolean), true(Boolean), false(Boolean), null, null, 1(Integer), 2(Integer), (String), null
2021-03-27 14:03:16.530 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.E.insertExecution : <== Updates: 1
2021-03-27 14:03:16.531 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : inserting: Task[id=72506, name=部门领导审批]
2021-03-27 14:03:16.534 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.entity.TaskEntity.insertTask : ==> Preparing: insert into ACT_RU_TASK (ID_, REV_, NAME_, PARENT_TASK_ID_, DESCRIPTION_, PRIORITY_, CREATE_TIME_, OWNER_, ASSIGNEE_, DELEGATION_, EXECUTION_ID_, PROC_INST_ID_, PROC_DEF_ID_, TASK_DEF_KEY_, DUE_DATE_, CATEGORY_, SUSPENSION_STATE_, TENANT_ID_, FORM_KEY_) values (?, 1, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? )
2021-03-27 14:03:16.558 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.entity.TaskEntity.insertTask : ==> Parameters: 72506(String), 部门领导审批(String), null, null, 50(Integer), 2021-03-27 14:03:16.242(Timestamp), null, admin(String), null, 72501(String), 72501(String), reimbursement-2:2:70011(String), usertask1(String), null, null, 1(Integer), (String), null
2021-03-27 14:03:16.561 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.entity.TaskEntity.insertTask : <== Updates: 1
2021-03-27 14:03:16.563 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : inserting: IdentityLinkEntity[id=72503, type=starter, userId=admin, processInstanceId=72501]
2021-03-27 14:03:16.565 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.I.insertIdentityLink : ==> Preparing: insert into ACT_RU_IDENTITYLINK (ID_, REV_, TYPE_, USER_ID_, GROUP_ID_, TASK_ID_, PROC_INST_ID_, PROC_DEF_ID_) values (?, 1, ?, ?, ?, ?, ?, ?)
2021-03-27 14:03:16.575 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.I.insertIdentityLink : ==> Parameters: 72503(String), starter(String), admin(String), null, null, 72501(String), null
2021-03-27 14:03:16.578 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.I.insertIdentityLink : <== Updates: 1
2021-03-27 14:03:16.579 DEBUG 9300 --- [nio-8080-exec-2] o.activiti.engine.impl.db.DbSqlSession : inserting: VariableInstanceEntity[id=72502, name=startUserId, type=string, textValue=admin]
2021-03-27 14:03:16.580 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.V.insertVariableInstance : ==> Preparing: insert into ACT_RU_VARIABLE (ID_, REV_, TYPE_, NAME_, PROC_INST_ID_, EXECUTION_ID_, TASK_ID_, BYTEARRAY_ID_, DOUBLE_, LONG_ , TEXT_, TEXT2_) values ( ?, 1, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? )
2021-03-27 14:03:16.595 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.V.insertVariableInstance : ==> Parameters: 72502(String), string(String), startUserId(String), 72501(String), 72501(String), null, null, null, null, admin(String), null
2021-03-27 14:03:16.598 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.i.p.e.V.insertVariableInstance : <== Updates: 1
2021-03-27 14:03:16.639 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor : --- StartProcessInstanceCmd finished --------------------------------------------------------
2021-03-27 14:03:16.640 DEBUG 9300 --- [nio-8080-exec-2] o.a.e.impl.interceptor.LogInterceptor :
首先查询流程定义
接下来开始创建流程实例 过程比较繁琐
最后的结果如下
在业务表单中对应的数据
通过以上的操作就开启了一个流程实例了。接下来相关的经办人就可以查询到流程中对应的任务。在控制层通过重定向实现的。
2021-03-27 14:18:50.977 DEBUG 9300 --- [nio-8080-exec-4] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:18:50.978 DEBUG 9300 --- [nio-8080-exec-4] o.a.e.impl.interceptor.LogInterceptor : --- starting TaskQueryImpl --------------------------------------------------------
2021-03-27 14:18:51.065 DEBUG 9300 --- [nio-8080-exec-4] o.a.e.i.p.e.G.selectGroupsByUserId : ==> Preparing: select g.* from ACT_ID_GROUP g, ACT_ID_MEMBERSHIP membership where g.ID_ = membership.GROUP_ID_ and membership.USER_ID_ = ?
2021-03-27 14:18:51.067 DEBUG 9300 --- [nio-8080-exec-4] o.a.e.i.p.e.G.selectGroupsByUserId : ==> Parameters: admin(String)
2021-03-27 14:18:51.074 DEBUG 9300 --- [nio-8080-exec-4] o.a.e.i.p.e.G.selectGroupsByUserId : <== Total: 0
2021-03-27 14:18:51.092 DEBUG 9300 --- [nio-8080-exec-4] o.a.e.i.p.e.T.selectTaskByQueryCriteria : ==> Preparing: select distinct RES.* from ACT_RU_TASK RES left join ACT_RU_IDENTITYLINK I on I.TASK_ID_ = RES.ID_ inner join ACT_RE_PROCDEF D on RES.PROC_DEF_ID_ = D.ID_ WHERE D.KEY_ = ? and RES.SUSPENSION_STATE_ = 1 and (RES.ASSIGNEE_ = ? or (RES.ASSIGNEE_ is null and I.TYPE_ = 'candidate' and (I.USER_ID_ = ? ))) order by RES.ID_ desc LIMIT ? OFFSET ?
2021-03-27 14:18:51.095 DEBUG 9300 --- [nio-8080-exec-4] o.a.e.i.p.e.T.selectTaskByQueryCriteria : ==> Parameters: reimbursement-2(String), admin(String), admin(String), 2147483647(Integer), 0(Integer)
2021-03-27 14:18:51.102 TRACE 9300 --- [nio-8080-exec-4] o.a.e.i.p.e.T.selectTaskByQueryCriteria : <== Columns: ID_, REV_, EXECUTION_ID_, PROC_INST_ID_, PROC_DEF_ID_, NAME_, PARENT_TASK_ID_, DESCRIPTION_, TASK_DEF_KEY_, OWNER_, ASSIGNEE_, DELEGATION_, PRIORITY_, CREATE_TIME_, DUE_DATE_, CATEGORY_, SUSPENSION_STATE_, TENANT_ID_, FORM_KEY_
2021-03-27 14:18:51.107 TRACE 9300 --- [nio-8080-exec-4] o.a.e.i.p.e.T.selectTaskByQueryCriteria : <== Row: 72506, 1, 72501, 72501, reimbursement-2:2:70011, 部门领导审批, null, null, usertask1, null, admin, null, 50, 2021-03-27 14:03:16.242, null, null, 1, , null
2021-03-27 14:18:51.115 DEBUG 9300 --- [nio-8080-exec-4] o.a.e.i.p.e.T.selectTaskByQueryCriteria : <== Total: 1
2021-03-27 14:18:51.117 TRACE 9300 --- [nio-8080-exec-4] o.activiti.engine.impl.db.DbSqlSession : loaded object 'Task[id=72506, name=部门领导审批]' was not updated
2021-03-27 14:18:51.117 DEBUG 9300 --- [nio-8080-exec-4] o.activiti.engine.impl.db.DbSqlSession : flush summary: 0 insert, 0 update, 0 delete.
2021-03-27 14:18:51.119 DEBUG 9300 --- [nio-8080-exec-4] o.activiti.engine.impl.db.DbSqlSession : now executing flush...
2021-03-27 14:18:51.123 DEBUG 9300 --- [nio-8080-exec-4] o.a.e.impl.interceptor.LogInterceptor : --- TaskQueryImpl finished --------------------------------------------------------
2021-03-27 14:18:51.124 DEBUG 9300 --- [nio-8080-exec-4] o.a.e.impl.interceptor.LogInterceptor :
通过reimbursement-2_list.jsp
页面渲染
<%@ page language="java" import="java.util.*" contentType="text/html; charset=utf8" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt" %>
<%
String path = request.getContextPath();
String basePath = request.getScheme() + "://"
+ request.getServerName() + ":" + request.getServerPort()
+ path + "/";
%>
<!DOCTYPE html>
<html lang="en">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf8" />
<title>Zioer-Activiti示例</title>
<link rel="stylesheet" rev="stylesheet" href="<%=basePath%>css/style.css" type="text/css" media="all" />
<script language=JavaScript>
</script>
</head>
<body class="ContentBody">
<form action="add" method="post" name="fom" id="fom">
<div class="MainDiv">
<table width="90%" border="0" cellpadding="0" cellspacing="0" class="CContent">
<tr>
<th class="tablestyle_title" >费用报销管理(业务表单)-待办工作</th>
</tr>
<tr>
<td class="CPanel">
<table id="subtree1" style="DISPLAY: " width="100%" border="0" cellspacing="0" cellpadding="0">
<tr>
<td><table width="95%" border="0" align="center" cellpadding="0" cellspacing="0">
<tr>
<td height="40" class="font42">
<table width="100%" border="0" cellpadding="4" cellspacing="1" bgcolor="#FFFFEE" class="newfont03">
<tr class="CTitle" >
<td height="22" colspan="5" align="center" style="font-size:16px">当前用户办理工作列表</td>
</tr>
<tr bgcolor="#EEEEEE">
<td width="10%" height="30">任务ID</td>
<td width="20%">当前节点</td>
<td width="20%">办理人</td>
<td width="36%">创建时间</td>
<td width="17%">操作</td>
</tr>
<c:forEach items="${list}" var="var" varStatus="vs">
<tr <c:if test="${vs.count%2==0}">bgcolor="#AAAABB"</c:if> align="left" >
<td >${var.id}</td>
<td height="30">${var.name}</td>
<td >${var.assignee}</td>
<td ><fmt:formatDate value="${var.createTime}" type="both"/></td>
<td ><a href="<%=basePath%>bussform/startform/${var.id}">办理</a></td>
</tr>
</c:forEach>
</table></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</div>
</form>
</body>
</html>
点击办理,此时会将任务Id传递到后台,根据这个任务ID就可以查询到相应的任务,在任务当中又包含了业务表单的主键,就可以查询到表单相关的数据了。
2021-03-27 14:26:48.694 DEBUG 9300 --- [nio-8080-exec-3] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:26:48.695 DEBUG 9300 --- [nio-8080-exec-3] o.a.e.impl.interceptor.LogInterceptor : --- starting TaskQueryImpl --------------------------------------------------------
2021-03-27 14:26:48.776 DEBUG 9300 --- [nio-8080-exec-3] o.a.e.i.p.e.T.selectTaskByQueryCriteria : ==> Preparing: select distinct RES.* from ACT_RU_TASK RES WHERE RES.ID_ = ? order by RES.ID_ asc LIMIT ? OFFSET ?
2021-03-27 14:26:48.782 DEBUG 9300 --- [nio-8080-exec-3] o.a.e.i.p.e.T.selectTaskByQueryCriteria : ==> Parameters: 72506(String), 2147483647(Integer), 0(Integer)
2021-03-27 14:26:48.788 TRACE 9300 --- [nio-8080-exec-3] o.a.e.i.p.e.T.selectTaskByQueryCriteria : <== Columns: ID_, REV_, EXECUTION_ID_, PROC_INST_ID_, PROC_DEF_ID_, NAME_, PARENT_TASK_ID_, DESCRIPTION_, TASK_DEF_KEY_, OWNER_, ASSIGNEE_, DELEGATION_, PRIORITY_, CREATE_TIME_, DUE_DATE_, CATEGORY_, SUSPENSION_STATE_, TENANT_ID_, FORM_KEY_
2021-03-27 14:26:48.791 TRACE 9300 --- [nio-8080-exec-3] o.a.e.i.p.e.T.selectTaskByQueryCriteria : <== Row: 72506, 1, 72501, 72501, reimbursement-2:2:70011, 部门领导审批, null, null, usertask1, null, admin, null, 50, 2021-03-27 14:03:16.242, null, null, 1, , null
2021-03-27 14:26:48.797 DEBUG 9300 --- [nio-8080-exec-3] o.a.e.i.p.e.T.selectTaskByQueryCriteria : <== Total: 1
2021-03-27 14:26:48.799 TRACE 9300 --- [nio-8080-exec-3] o.activiti.engine.impl.db.DbSqlSession : loaded object 'Task[id=72506, name=部门领导审批]' was not updated
2021-03-27 14:26:48.799 DEBUG 9300 --- [nio-8080-exec-3] o.activiti.engine.impl.db.DbSqlSession : flush summary: 0 insert, 0 update, 0 delete.
2021-03-27 14:26:48.800 DEBUG 9300 --- [nio-8080-exec-3] o.activiti.engine.impl.db.DbSqlSession : now executing flush...
2021-03-27 14:26:48.806 DEBUG 9300 --- [nio-8080-exec-3] o.a.e.impl.interceptor.LogInterceptor : --- TaskQueryImpl finished --------------------------------------------------------
2021-03-27 14:26:48.807 DEBUG 9300 --- [nio-8080-exec-3] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:27:19.041 DEBUG 9300 --- [nio-8080-exec-3] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:27:19.050 DEBUG 9300 --- [nio-8080-exec-3] o.a.e.impl.interceptor.LogInterceptor : --- starting ProcessInstanceQueryImpl --------------------------------------------------------
2021-03-27 14:27:19.115 DEBUG 9300 --- [nio-8080-exec-3] e.E.selectProcessInstanceByQueryCriteria : ==> Preparing: select distinct RES.* , P.KEY_ as ProcessDefinitionKey, P.ID_ as ProcessDefinitionId, P.NAME_ as ProcessDefinitionName, P.VERSION_ as ProcessDefinitionVersion, P.DEPLOYMENT_ID_ as DeploymentId from ACT_RU_EXECUTION RES inner join ACT_RE_PROCDEF P on RES.PROC_DEF_ID_ = P.ID_ WHERE RES.PARENT_ID_ is null and RES.ID_ = ? and RES.PROC_INST_ID_ = ? and (RES.SUSPENSION_STATE_ = 1) order by RES.ID_ asc LIMIT ? OFFSET ?
2021-03-27 14:27:19.119 DEBUG 9300 --- [nio-8080-exec-3] e.E.selectProcessInstanceByQueryCriteria : ==> Parameters: 72501(String), 72501(String), 2147483647(Integer), 0(Integer)
2021-03-27 14:27:19.129 TRACE 9300 --- [nio-8080-exec-3] e.E.selectProcessInstanceByQueryCriteria : <== Columns: ID_, REV_, PROC_INST_ID_, BUSINESS_KEY_, PARENT_ID_, PROC_DEF_ID_, SUPER_EXEC_, ACT_ID_, IS_ACTIVE_, IS_CONCURRENT_, IS_SCOPE_, IS_EVENT_SCOPE_, SUSPENSION_STATE_, CACHED_ENT_STATE_, TENANT_ID_, NAME_, LOCK_TIME_, ProcessDefinitionKey, ProcessDefinitionId, ProcessDefinitionName, ProcessDefinitionVersion, DeploymentId
2021-03-27 14:27:19.131 TRACE 9300 --- [nio-8080-exec-3] e.E.selectProcessInstanceByQueryCriteria : <== Row: 72501, 1, 72501, b2e214608e6711eb857c0242ac110002, null, reimbursement-2:2:70011, null, usertask1, 1, 0, 1, 0, 1, 2, , null, null, reimbursement-2, reimbursement-2:2:70011, 费用报销-2, 2, 70001
2021-03-27 14:27:19.166 DEBUG 9300 --- [nio-8080-exec-3] e.E.selectProcessInstanceByQueryCriteria : <== Total: 1
2021-03-27 14:27:19.170 TRACE 9300 --- [nio-8080-exec-3] o.activiti.engine.impl.db.DbSqlSession : loaded object 'ProcessInstance[72501]' was not updated
2021-03-27 14:27:19.171 DEBUG 9300 --- [nio-8080-exec-3] o.activiti.engine.impl.db.DbSqlSession : flush summary: 0 insert, 0 update, 0 delete.
2021-03-27 14:27:19.173 DEBUG 9300 --- [nio-8080-exec-3] o.activiti.engine.impl.db.DbSqlSession : now executing flush...
2021-03-27 14:27:19.181 DEBUG 9300 --- [nio-8080-exec-3] o.a.e.impl.interceptor.LogInterceptor : --- ProcessInstanceQueryImpl finished --------------------------------------------------------
2021-03-27 14:27:19.182 DEBUG 9300 --- [nio-8080-exec-3] o.a.e.impl.interceptor.LogInterceptor :
接下来通过reimbursement-2_edit.jsp
渲染
<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core"%>
<%@ taglib prefix="fmt" uri="http://java.sun.com/jsp/jstl/fmt"%>
<%
String path = request.getContextPath();
String basePath = request.getScheme()+"://"+request.getServerName()+":"+request.getServerPort()+path+"/";
%>
<html lang="en">
<head>
<title>费用报销-审批</title>
<link rel="stylesheet" rev="stylesheet" href="<%=basePath%>css/style.css" type="text/css" media="all" />
<script type="text/javascript" src="<%=basePath%>js/My97DatePicker/WdatePicker.js"></script>
<script language=JavaScript>
function save(){
document.getElementById("form").submit();
}
</script>
</head>
<body>
<form action="save/${taskId}" method="post" name="form" id="form">
<div class="MainDiv">
<table width="60%" border="0" cellpadding="0" cellspacing="0" class="CContent">
<tr>
<th class="tablestyle_title" >费用报销(业务表单)-审批</th>
</tr>
<tr>
<td class="CPanel">
<table border="0" cellpadding="0" cellspacing="0" style="width:100%">
<TR>
<TD width="100%">
<fieldset style="height:100%;">
<legend>内容填写</legend>
<c:choose>
<c:when test="${actId=='usertask1'}">
<table border="0" cellpadding="2" cellspacing="1" style="width:100%">
<tr>
<td nowrap align="right" width="13%">申请人</td>
<td colspan="3">${data.userId}</td>
</tr>
<tr>
<td nowrap align="right" width="13%">费用</td>
<td width="19%">${data.fee}</td>
<td width="13%" align="right" nowrap>费用类型</td>
<td width="55%">${data.type}</td>
</tr>
<tr>
<td nowrap align="right">发生日期</td>
<td colspan="3"><fmt:formatDate type="date" value="${data.feedate}" /></td>
</tr>
<tr>
<td nowrap align="right" width="13%">说明</td>
<td colspan="3">${data.note}</td>
</tr>
<tr>
<td nowrap align="right" width="13%">部门领导意见</td>
<td colspan="3">
<textarea id='bmyj' name='bmyj' rows="5" cols="50"></textarea>
<input type="hidden" name="id" id="id" value="${data.id}" />
</td>
</tr>
</table>
</c:when>
<c:when test="${actId=='usertask2'}">
<table border="0" cellpadding="2" cellspacing="1" style="width:100%">
<tr>
<td nowrap align="right" width="13%">申请人</td>
<td colspan="3">${data.userId}</td>
</tr>
<tr>
<td nowrap align="right" width="13%">费用</td>
<td width="19%">${data.fee}</td>
<td width="13%" align="right" nowrap>核实费用</td>
<td width="55%"><input type='text' id='refee' name='refee' value='' /></td>
</tr>
<tr>
<td nowrap align="right">发生日期</td>
<td><fmt:formatDate type="date" value="${data.feedate}" /></td>
<td width="13%" align="right" nowrap>费用类型</td>
<td width="55%">${data.type}</td>
</tr>
<tr>
<td nowrap align="right" width="13%">说明</td>
<td colspan="3">${data.note}</td>
</tr>
<tr>
<td nowrap align="right" width="13%">部门领导意见</td>
<td colspan="3">${data.bmyj}</td>
</tr>
<tr>
<td nowrap align="right" width="13%">财务部门意见</td>
<td colspan="3">
<textarea id='bzhu' name='bzhu' rows="5" cols="50"></textarea>
<input type="hidden" name="id" id="id" value="${data.id}" />
</td>
</tr>
</table>
</c:when>
<c:otherwise>
<table border="0" cellpadding="2" cellspacing="1" style="width:100%">
<tr>
<td nowrap align="right" width="13%">费用</td>
<td width="19%">${data.fee}</td>
<td width="13%" align="right" nowrap>核实费用</td>
<td width="55%">${data.refee}</td>
</tr>
<tr>
<td nowrap align="right">发生日期</td>
<td><fmt:formatDate type="date" value="${data.feedate}" /></td>
<td width="13%" align="right" nowrap>费用类型</td>
<td width="55%">${data.type}</td>
</tr>
<tr>
<td nowrap align="right" width="13%">说明</td>
<td colspan="3">${data.note}</td>
</tr>
<tr>
<td nowrap align="right" width="13%">部门领导意见</td>
<td colspan="3">${data.bmyj}</td>
</tr>
<tr>
<td nowrap align="right" width="13%">财务部门意见</td>
<td colspan="3">
${data.bzhu}
<input type="hidden" name="id" id="id" value="${data.id}" />
</td>
</tr>
</table>
</c:otherwise>
</c:choose>
</fieldset>
</TD>
</TR>
</TABLE>
</td>
</tr>
<tr>
<TD colspan="2" align="center" height="50px">
<input type="button" name="Submit" value="保存" class="button" onclick="save();"/>
<input type="button" name="Submit2" value="返回" class="button" onclick="window.history.go(-1);"/>
</TD>
</tr>
</table>
</div>
</form>
</body>
</html>
注意在这里还传递了一个actId,这样就可以在一个jsp包含多个流程的信息了。在上面的jsp中就包含了usertask1、usertask2、usertask3的表单。
最后渲染的结果如下所示
填写意见并保存,此时就会进入到完成当前任务的阶段了,区别于其他表单,这里需要更新业务表单的数据了。其实整个过程无非就是把业务表单数据传来传去而已。
2021-03-27 14:35:53.274 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.impl.interceptor.LogInterceptor :
2021-03-27 14:35:53.275 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.impl.interceptor.LogInterceptor : --- starting CompleteTaskCmd --------------------------------------------------------
2021-03-27 14:35:53.346 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.entity.TaskEntity.selectTask : ==> Preparing: select * from ACT_RU_TASK where ID_ = ?
2021-03-27 14:35:53.349 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.entity.TaskEntity.selectTask : ==> Parameters: 72506(String)
2021-03-27 14:35:53.358 TRACE 9300 --- [nio-8080-exec-9] o.a.e.i.p.entity.TaskEntity.selectTask : <== Columns: ID_, REV_, EXECUTION_ID_, PROC_INST_ID_, PROC_DEF_ID_, NAME_, PARENT_TASK_ID_, DESCRIPTION_, TASK_DEF_KEY_, OWNER_, ASSIGNEE_, DELEGATION_, PRIORITY_, CREATE_TIME_, DUE_DATE_, CATEGORY_, SUSPENSION_STATE_, TENANT_ID_, FORM_KEY_
2021-03-27 14:35:53.361 TRACE 9300 --- [nio-8080-exec-9] o.a.e.i.p.entity.TaskEntity.selectTask : <== Row: 72506, 1, 72501, 72501, reimbursement-2:2:70011, 部门领导审批, null, null, usertask1, null, admin, null, 50, 2021-03-27 14:03:16.242, null, null, 1, , null
2021-03-27 14:35:53.371 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.entity.TaskEntity.selectTask : <== Total: 1
2021-03-27 14:35:53.374 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.E.selectExecution : ==> Preparing: select * from ACT_RU_EXECUTION where ID_ = ?
2021-03-27 14:35:53.376 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.E.selectExecution : ==> Parameters: 72501(String)
2021-03-27 14:35:53.389 TRACE 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.E.selectExecution : <== Columns: ID_, REV_, PROC_INST_ID_, BUSINESS_KEY_, PARENT_ID_, PROC_DEF_ID_, SUPER_EXEC_, ACT_ID_, IS_ACTIVE_, IS_CONCURRENT_, IS_SCOPE_, IS_EVENT_SCOPE_, SUSPENSION_STATE_, CACHED_ENT_STATE_, TENANT_ID_, NAME_, LOCK_TIME_
2021-03-27 14:35:53.391 TRACE 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.E.selectExecution : <== Row: 72501, 1, 72501, b2e214608e6711eb857c0242ac110002, null, reimbursement-2:2:70011, null, usertask1, 1, 0, 1, 0, 1, 2, , null, null
2021-03-27 14:35:53.401 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.E.selectExecution : <== Total: 1
2021-03-27 14:35:53.403 DEBUG 9300 --- [nio-8080-exec-9] e.I.selectIdentityLinksByProcessInstance : ==> Preparing: select * from ACT_RU_IDENTITYLINK where PROC_INST_ID_ = ?
2021-03-27 14:35:53.405 DEBUG 9300 --- [nio-8080-exec-9] e.I.selectIdentityLinksByProcessInstance : ==> Parameters: 72501(String)
2021-03-27 14:35:53.410 TRACE 9300 --- [nio-8080-exec-9] e.I.selectIdentityLinksByProcessInstance : <== Columns: ID_, REV_, GROUP_ID_, TYPE_, USER_ID_, TASK_ID_, PROC_INST_ID_, PROC_DEF_ID_
2021-03-27 14:35:53.411 TRACE 9300 --- [nio-8080-exec-9] e.I.selectIdentityLinksByProcessInstance : <== Row: 72503, 1, null, starter, admin, null, 72501, null
2021-03-27 14:35:53.414 DEBUG 9300 --- [nio-8080-exec-9] e.I.selectIdentityLinksByProcessInstance : <== Total: 1
2021-03-27 14:35:53.416 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.T.selectTasksByParentTaskId : ==> Preparing: select * from ACT_RU_TASK where PARENT_TASK_ID_ = ?
2021-03-27 14:35:53.418 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.T.selectTasksByParentTaskId : ==> Parameters: 72506(String)
2021-03-27 14:35:53.424 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.T.selectTasksByParentTaskId : <== Total: 0
2021-03-27 14:35:53.425 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.I.selectIdentityLinksByTask : ==> Preparing: select * from ACT_RU_IDENTITYLINK where TASK_ID_ = ?
2021-03-27 14:35:53.427 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.I.selectIdentityLinksByTask : ==> Parameters: 72506(String)
2021-03-27 14:35:53.431 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.I.selectIdentityLinksByTask : <== Total: 0
2021-03-27 14:35:53.434 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.V.selectVariablesByTaskId : ==> Preparing: select * from ACT_RU_VARIABLE where TASK_ID_ = ?
2021-03-27 14:35:53.436 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.V.selectVariablesByTaskId : ==> Parameters: 72506(String)
2021-03-27 14:35:53.440 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.V.selectVariablesByTaskId : <== Total: 0
2021-03-27 14:35:53.442 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: AUDIT
2021-03-27 14:35:53.444 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.H.selectHistoricTaskInstance : ==> Preparing: select * from ACT_HI_TASKINST where ID_ = ?
2021-03-27 14:35:53.445 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.H.selectHistoricTaskInstance : ==> Parameters: 72506(String)
2021-03-27 14:35:53.452 TRACE 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.H.selectHistoricTaskInstance : <== Columns: ID_, PROC_DEF_ID_, TASK_DEF_KEY_, PROC_INST_ID_, EXECUTION_ID_, NAME_, PARENT_TASK_ID_, DESCRIPTION_, OWNER_, ASSIGNEE_, START_TIME_, CLAIM_TIME_, END_TIME_, DURATION_, DELETE_REASON_, PRIORITY_, DUE_DATE_, FORM_KEY_, CATEGORY_, TENANT_ID_
2021-03-27 14:35:53.455 TRACE 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.H.selectHistoricTaskInstance : <== Row: 72506, reimbursement-2:2:70011, usertask1, 72501, 72501, 部门领导审批, null, null, null, admin, 2021-03-27 14:03:16.253, null, null, null, null, 50, null, null, null,
2021-03-27 14:35:53.468 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.H.selectHistoricTaskInstance : <== Total: 1
2021-03-27 14:35:53.475 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.T.selectTasksByExecutionId : ==> Preparing: select distinct T.* from ACT_RU_TASK T where T.EXECUTION_ID_ = ?
2021-03-27 14:35:53.477 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.T.selectTasksByExecutionId : ==> Parameters: 72501(String)
2021-03-27 14:35:53.486 TRACE 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.T.selectTasksByExecutionId : <== Columns: ID_, REV_, EXECUTION_ID_, PROC_INST_ID_, PROC_DEF_ID_, NAME_, PARENT_TASK_ID_, DESCRIPTION_, TASK_DEF_KEY_, OWNER_, ASSIGNEE_, DELEGATION_, PRIORITY_, CREATE_TIME_, DUE_DATE_, CATEGORY_, SUSPENSION_STATE_, TENANT_ID_, FORM_KEY_
2021-03-27 14:35:53.490 TRACE 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.T.selectTasksByExecutionId : <== Row: 72506, 1, 72501, 72501, reimbursement-2:2:70011, 部门领导审批, null, null, usertask1, null, admin, null, 50, 2021-03-27 14:03:16.242, null, null, 1, , null
2021-03-27 14:35:53.499 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.T.selectTasksByExecutionId : <== Total: 1
2021-03-27 14:35:53.501 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.b.behavior.BpmnActivityBehavior : Leaving activity 'usertask1'
2021-03-27 14:35:53.502 TRACE 9300 --- [nio-8080-exec-9] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationTransitionNotifyListenerEnd@673caa1f on org.activiti.engine.impl.interceptor.CommandContext@7fb16420
2021-03-27 14:35:53.503 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: ACTIVITY
2021-03-27 14:35:53.531 DEBUG 9300 --- [nio-8080-exec-9] HistoricActivityInstancesByQueryCriteria : ==> Preparing: select RES.* from ACT_HI_ACTINST RES WHERE RES.EXECUTION_ID_ = ? and RES.ACT_ID_ = ? and RES.END_TIME_ is null order by RES.ID_ asc LIMIT ? OFFSET ?
2021-03-27 14:35:53.534 DEBUG 9300 --- [nio-8080-exec-9] HistoricActivityInstancesByQueryCriteria : ==> Parameters: 72501(String), usertask1(String), 1(Integer), 0(Integer)
2021-03-27 14:35:53.538 TRACE 9300 --- [nio-8080-exec-9] HistoricActivityInstancesByQueryCriteria : <== Columns: ID_, PROC_DEF_ID_, PROC_INST_ID_, EXECUTION_ID_, ACT_ID_, TASK_ID_, CALL_PROC_INST_ID_, ACT_NAME_, ACT_TYPE_, ASSIGNEE_, START_TIME_, END_TIME_, DURATION_, TENANT_ID_
2021-03-27 14:35:53.540 TRACE 9300 --- [nio-8080-exec-9] HistoricActivityInstancesByQueryCriteria : <== Row: 72505, reimbursement-2:2:70011, 72501, 72501, usertask1, 72506, null, 部门领导审批, userTask, admin, 2021-03-27 14:03:16.240, null, null,
2021-03-27 14:35:53.547 DEBUG 9300 --- [nio-8080-exec-9] HistoricActivityInstancesByQueryCriteria : <== Total: 1
2021-03-27 14:35:53.548 TRACE 9300 --- [nio-8080-exec-9] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationTransitionNotifyListenerEnd@673caa1f on org.activiti.engine.impl.interceptor.CommandContext@7fb16420
2021-03-27 14:35:53.550 TRACE 9300 --- [nio-8080-exec-9] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationTransitionDestroyScope@30f8c7eb on org.activiti.engine.impl.interceptor.CommandContext@7fb16420
2021-03-27 14:35:53.551 TRACE 9300 --- [nio-8080-exec-9] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationTransitionNotifyListenerTake@3a4ee6a3 on org.activiti.engine.impl.interceptor.CommandContext@7fb16420
2021-03-27 14:35:53.552 DEBUG 9300 --- [nio-8080-exec-9] micOperationTransitionNotifyListenerTake : ProcessInstance[72501] takes transition (usertask1)--flow2-->(usertask2)
2021-03-27 14:35:53.554 TRACE 9300 --- [nio-8080-exec-9] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationTransitionCreateScope@26f1141f on org.activiti.engine.impl.interceptor.CommandContext@7fb16420
2021-03-27 14:35:53.555 TRACE 9300 --- [nio-8080-exec-9] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationTransitionNotifyListenerStart@2e0c167b on org.activiti.engine.impl.interceptor.CommandContext@7fb16420
2021-03-27 14:35:53.556 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: ACTIVITY
2021-03-27 14:35:53.558 TRACE 9300 --- [nio-8080-exec-9] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationTransitionNotifyListenerStart@2e0c167b on org.activiti.engine.impl.interceptor.CommandContext@7fb16420
2021-03-27 14:35:53.559 TRACE 9300 --- [nio-8080-exec-9] o.a.e.impl.interceptor.CommandContext : AtomicOperation: org.activiti.engine.impl.pvm.runtime.AtomicOperationActivityExecute@5c870ea0 on org.activiti.engine.impl.interceptor.CommandContext@7fb16420
2021-03-27 14:35:53.560 DEBUG 9300 --- [nio-8080-exec-9] a.e.i.p.r.AtomicOperationActivityExecute : ProcessInstance[72501] executes Activity(usertask2): org.activiti.engine.impl.bpmn.behavior.UserTaskActivityBehavior
2021-03-27 14:35:53.562 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: AUDIT
2021-03-27 14:35:53.563 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: AUDIT
2021-03-27 14:35:53.565 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: AUDIT
2021-03-27 14:35:53.566 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: AUDIT
2021-03-27 14:35:53.567 DEBUG 9300 --- [nio-8080-exec-9] a.e.i.p.e.V.selectVariablesByExecutionId : ==> Preparing: select * from ACT_RU_VARIABLE where EXECUTION_ID_ = ? and TASK_ID_ is null
2021-03-27 14:35:53.569 DEBUG 9300 --- [nio-8080-exec-9] a.e.i.p.e.V.selectVariablesByExecutionId : ==> Parameters: 72501(String)
2021-03-27 14:35:53.574 TRACE 9300 --- [nio-8080-exec-9] a.e.i.p.e.V.selectVariablesByExecutionId : <== Columns: ID_, REV_, TYPE_, NAME_, EXECUTION_ID_, PROC_INST_ID_, TASK_ID_, BYTEARRAY_ID_, DOUBLE_, LONG_, TEXT_, TEXT2_
2021-03-27 14:35:53.575 TRACE 9300 --- [nio-8080-exec-9] a.e.i.p.e.V.selectVariablesByExecutionId : <== Row: 72502, 1, string, startUserId, 72501, 72501, null, null, null, null, admin, null
2021-03-27 14:35:53.582 DEBUG 9300 --- [nio-8080-exec-9] a.e.i.p.e.V.selectVariablesByExecutionId : <== Total: 1
2021-03-27 14:35:53.584 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: AUDIT
2021-03-27 14:35:53.585 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: ACTIVITY
2021-03-27 14:35:53.586 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.history.DefaultHistoryManager : Current history level: AUDIT, level required: ACTIVITY
2021-03-27 14:35:53.587 TRACE 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : loaded object 'VariableInstanceEntity[id=72502, name=startUserId, type=string, textValue=admin]' was not updated
2021-03-27 14:35:53.588 TRACE 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : loaded object 'IdentityLinkEntity[id=72503, type=starter, userId=admin, processInstanceId=72501]' was not updated
2021-03-27 14:35:53.589 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : insert HistoricActivityInstanceEntity[activityId=usertask2, activityName=财务部门审批]
2021-03-27 14:35:53.589 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : insert Task[id=72508, name=财务部门审批]
2021-03-27 14:35:53.590 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : insert HistoricTaskInstanceEntity[id=72508, name=财务部门审批]
2021-03-27 14:35:53.591 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : update HistoricActivityInstanceEntity[activityId=usertask1, activityName=部门领导审批]
2021-03-27 14:35:53.591 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : update ProcessInstance[72501]
2021-03-27 14:35:53.592 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : update HistoricTaskInstanceEntity[id=72506, name=部门领导审批]
2021-03-27 14:35:53.593 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : delete Task[id=72506, name=部门领导审批]
2021-03-27 14:35:53.594 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : flush summary: 3 insert, 3 update, 1 delete.
2021-03-27 14:35:53.595 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : now executing flush...
2021-03-27 14:35:53.595 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : inserting: HistoricTaskInstanceEntity[id=72508, name=财务部门审批]
2021-03-27 14:35:53.597 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.H.insertHistoricTaskInstance : ==> Preparing: insert into ACT_HI_TASKINST ( ID_, PROC_DEF_ID_, PROC_INST_ID_, EXECUTION_ID_, NAME_, PARENT_TASK_ID_, DESCRIPTION_, OWNER_, ASSIGNEE_, START_TIME_, CLAIM_TIME_, END_TIME_, DURATION_, DELETE_REASON_, TASK_DEF_KEY_, FORM_KEY_, PRIORITY_, DUE_DATE_, CATEGORY_, TENANT_ID_ ) values ( ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? )
2021-03-27 14:35:53.626 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.H.insertHistoricTaskInstance : ==> Parameters: 72508(String), reimbursement-2:2:70011(String), 72501(String), 72501(String), 财务部门审批(String), null, null, null, admin(String), 2021-03-27 14:35:53.563(Timestamp), null, null, null, null, usertask2(String), null, 50(Integer), null, null, (String)
2021-03-27 14:35:53.630 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.H.insertHistoricTaskInstance : <== Updates: 1
2021-03-27 14:35:53.631 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : inserting: HistoricActivityInstanceEntity[activityId=usertask2, activityName=财务部门审批]
2021-03-27 14:35:53.633 DEBUG 9300 --- [nio-8080-exec-9] e.i.p.e.H.insertHistoricActivityInstance : ==> Preparing: insert into ACT_HI_ACTINST ( ID_, PROC_DEF_ID_, PROC_INST_ID_, EXECUTION_ID_, ACT_ID_, TASK_ID_, CALL_PROC_INST_ID_, ACT_NAME_, ACT_TYPE_, ASSIGNEE_, START_TIME_, END_TIME_, DURATION_, TENANT_ID_ ) values ( ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? )
2021-03-27 14:35:53.656 DEBUG 9300 --- [nio-8080-exec-9] e.i.p.e.H.insertHistoricActivityInstance : ==> Parameters: 72507(String), reimbursement-2:2:70011(String), 72501(String), 72501(String), usertask2(String), 72508(String), null, 财务部门审批(String), userTask(String), admin(String), 2021-03-27 14:35:53.557(Timestamp), null, null, (String)
2021-03-27 14:35:53.659 DEBUG 9300 --- [nio-8080-exec-9] e.i.p.e.H.insertHistoricActivityInstance : <== Updates: 1
2021-03-27 14:35:53.660 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : inserting: Task[id=72508, name=财务部门审批]
2021-03-27 14:35:53.665 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.entity.TaskEntity.insertTask : ==> Preparing: insert into ACT_RU_TASK (ID_, REV_, NAME_, PARENT_TASK_ID_, DESCRIPTION_, PRIORITY_, CREATE_TIME_, OWNER_, ASSIGNEE_, DELEGATION_, EXECUTION_ID_, PROC_INST_ID_, PROC_DEF_ID_, TASK_DEF_KEY_, DUE_DATE_, CATEGORY_, SUSPENSION_STATE_, TENANT_ID_, FORM_KEY_) values (?, 1, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? )
2021-03-27 14:35:53.693 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.entity.TaskEntity.insertTask : ==> Parameters: 72508(String), 财务部门审批(String), null, null, 50(Integer), 2021-03-27 14:35:53.562(Timestamp), null, admin(String), null, 72501(String), 72501(String), reimbursement-2:2:70011(String), usertask2(String), null, null, 1(Integer), (String), null
2021-03-27 14:35:53.702 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.entity.TaskEntity.insertTask : <== Updates: 1
2021-03-27 14:35:53.703 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : updating: HistoricActivityInstanceEntity[activityId=usertask1, activityName=部门领导审批]
2021-03-27 14:35:53.706 DEBUG 9300 --- [nio-8080-exec-9] e.i.p.e.H.updateHistoricActivityInstance : ==> Preparing: update ACT_HI_ACTINST set EXECUTION_ID_ = ?, ASSIGNEE_ = ?, END_TIME_ = ?, DURATION_ = ? where ID_ = ?
2021-03-27 14:35:53.710 DEBUG 9300 --- [nio-8080-exec-9] e.i.p.e.H.updateHistoricActivityInstance : ==> Parameters: 72501(String), admin(String), 2021-03-27 14:35:53.548(Timestamp), 1957308(Long), 72505(String)
2021-03-27 14:35:53.717 DEBUG 9300 --- [nio-8080-exec-9] e.i.p.e.H.updateHistoricActivityInstance : <== Updates: 1
2021-03-27 14:35:53.718 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : updating: ProcessInstance[72501]
2021-03-27 14:35:53.721 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.E.updateExecution : ==> Preparing: update ACT_RU_EXECUTION set REV_ = ?, BUSINESS_KEY_ = ?, PROC_DEF_ID_ = ?, ACT_ID_ = ?, IS_ACTIVE_ = ?, IS_CONCURRENT_ = ?, IS_SCOPE_ = ?, IS_EVENT_SCOPE_ = ?, PARENT_ID_ = ?, SUPER_EXEC_ = ?, SUSPENSION_STATE_ = ?, CACHED_ENT_STATE_ = ?, NAME_ = ? where ID_ = ? and REV_ = ?
2021-03-27 14:35:53.731 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.E.updateExecution : ==> Parameters: 2(Integer), b2e214608e6711eb857c0242ac110002(String), reimbursement-2:2:70011(String), usertask2(String), true(Boolean), false(Boolean), true(Boolean), false(Boolean), null, null, 1(Integer), 2(Integer), null, 72501(String), 1(Integer)
2021-03-27 14:35:53.739 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.E.updateExecution : <== Updates: 1
2021-03-27 14:35:53.741 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : updating: HistoricTaskInstanceEntity[id=72506, name=部门领导审批]
2021-03-27 14:35:53.745 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.H.updateHistoricTaskInstance : ==> Preparing: update ACT_HI_TASKINST set PROC_DEF_ID_ = ?, EXECUTION_ID_ = ?, NAME_ = ?, PARENT_TASK_ID_ = ?, DESCRIPTION_ = ?, OWNER_ = ?, ASSIGNEE_ = ?, CLAIM_TIME_ = ?, END_TIME_ = ?, DURATION_ = ?, DELETE_REASON_ = ?, TASK_DEF_KEY_ = ?, FORM_KEY_ = ?, PRIORITY_ = ?, DUE_DATE_ = ?, CATEGORY_ = ? where ID_ = ?
2021-03-27 14:35:53.754 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.H.updateHistoricTaskInstance : ==> Parameters: reimbursement-2:2:70011(String), 72501(String), 部门领导审批(String), null, null, null, admin(String), null, 2021-03-27 14:35:53.469(Timestamp), 1957216(Long), completed(String), usertask1(String), null, 50(Integer), null, null, 72506(String)
2021-03-27 14:35:53.759 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.e.H.updateHistoricTaskInstance : <== Updates: 1
2021-03-27 14:35:53.761 DEBUG 9300 --- [nio-8080-exec-9] o.activiti.engine.impl.db.DbSqlSession : executing: delete Task[id=72506, name=部门领导审批]
2021-03-27 14:35:53.763 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.entity.TaskEntity.deleteTask : ==> Preparing: delete from ACT_RU_TASK where ID_ = ? and REV_ = ?
2021-03-27 14:35:53.769 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.entity.TaskEntity.deleteTask : ==> Parameters: 72506(String), 1(Integer)
2021-03-27 14:35:53.774 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.i.p.entity.TaskEntity.deleteTask : <== Updates: 1
2021-03-27 14:35:53.803 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.impl.interceptor.LogInterceptor : --- CompleteTaskCmd finished --------------------------------------------------------
2021-03-27 14:35:53.804 DEBUG 9300 --- [nio-8080-exec-9] o.a.e.impl.interceptor.LogInterceptor :
业务表单中的数据
接下来的流程就是办理、提交了,基本一致。