Compare commits
2 Commits
816f0ab5ff
...
07a997246b
| Author | SHA1 | Date | |
|---|---|---|---|
| 07a997246b | |||
| d4e6f6648d |
@@ -1,7 +1,6 @@
|
|||||||
package com.lanyuanxiaoyao.flowable.repository.memory;
|
package com.lanyuanxiaoyao.flowable.repository;
|
||||||
|
|
||||||
import com.lanyuanxiaoyao.flowable.model.Flow;
|
import com.lanyuanxiaoyao.flowable.model.Flow;
|
||||||
import com.lanyuanxiaoyao.flowable.repository.FlowRepository;
|
|
||||||
import java.util.Map;
|
import java.util.Map;
|
||||||
import java.util.UUID;
|
import java.util.UUID;
|
||||||
import java.util.concurrent.ConcurrentHashMap;
|
import java.util.concurrent.ConcurrentHashMap;
|
||||||
@@ -42,11 +42,6 @@ public class FlowService {
|
|||||||
// 保存流程实例
|
// 保存流程实例
|
||||||
flow = flowRepository.update(flow);
|
flow = flowRepository.update(flow);
|
||||||
|
|
||||||
// 自动提交第一个节点
|
|
||||||
FlowContext context = flow.createContext();
|
|
||||||
flow.getCurrentNodeObject().onApprove(context);
|
|
||||||
flow = updateFlow(flow, context);
|
|
||||||
|
|
||||||
// 如果第一个节点是系统节点,自动执行审批
|
// 如果第一个节点是系统节点,自动执行审批
|
||||||
if (flow.getCurrentNodeObject() instanceof SystemFlowNode) {
|
if (flow.getCurrentNodeObject() instanceof SystemFlowNode) {
|
||||||
return executeNode(flow);
|
return executeNode(flow);
|
||||||
|
|||||||
@@ -6,7 +6,7 @@ import com.lanyuanxiaoyao.flowable.node.LeaveRequestNode;
|
|||||||
import com.lanyuanxiaoyao.flowable.node.LeaveSystemCheckNode;
|
import com.lanyuanxiaoyao.flowable.node.LeaveSystemCheckNode;
|
||||||
import com.lanyuanxiaoyao.flowable.node.ManagerApprovalNode;
|
import com.lanyuanxiaoyao.flowable.node.ManagerApprovalNode;
|
||||||
import com.lanyuanxiaoyao.flowable.repository.FlowRepository;
|
import com.lanyuanxiaoyao.flowable.repository.FlowRepository;
|
||||||
import com.lanyuanxiaoyao.flowable.repository.memory.MemoryFlowRepository;
|
import com.lanyuanxiaoyao.flowable.repository.MemoryFlowRepository;
|
||||||
import com.lanyuanxiaoyao.flowable.service.FlowService;
|
import com.lanyuanxiaoyao.flowable.service.FlowService;
|
||||||
import org.junit.jupiter.api.BeforeEach;
|
import org.junit.jupiter.api.BeforeEach;
|
||||||
import org.junit.jupiter.api.DisplayName;
|
import org.junit.jupiter.api.DisplayName;
|
||||||
|
|||||||
Reference in New Issue
Block a user