Flowable 6.6.0 BPMN 사용자 가이드 - 7 BPMN 2.0 소개 - 7.3 입문: 10 분 튜 토리 얼 (11 - 12)
10638 단어 Flowable6.6.0BPMN 사용자 가이드- (6) 배치(7)
1. 입문
2. 설정
3 The Flowable API
4 Flowable 6.6.0 BPMN 사용자 가이드 - (4) Spring 집성
5 Spring Boot
6 배치
7 BPMN 2.0 안내
7.1 BPMN 은 무엇 입 니까?7.2 정의 절차 7.3 입문: 10 분 튜 토리 얼
《 Flowable 문서 대전 》
7.3.11 코드 개요
Combine all the snippets from previous sections, and you should have something like the following. The code takes into account that you probably will have started a few process instances through the Flowable app UI. It retrieves a list of tasks instead of one task, so it always works:
앞의 몇 절 에 있 는 모든 코드 세 션 을 합치 면 다음 과 같은 내용 을 얻 을 수 있 습 니 다.코드 는 Flowable 응용 UI (Flowable app UI) 를 통 해 몇 개의 프로 세 스 인 스 턴 스 를 시 작 했 을 수도 있 음 을 고려 합 니 다.작업 목록 이 아 닌 작업 목록 을 검색 하기 때문에 항상 유효 합 니 다.
public class TenMinuteTutorial {
public static void main(String[] args) {
// Create Flowable process engine
ProcessEngine processEngine = ProcessEngineConfiguration
.createStandaloneProcessEngineConfiguration()
.buildProcessEngine();
// Get Flowable services
RepositoryService repositoryService = processEngine.getRepositoryService();
RuntimeService runtimeService = processEngine.getRuntimeService();
// Deploy the process definition
repositoryService.createDeployment()
.addClasspathResource("FinancialReportProcess.bpmn20.xml")
.deploy();
// Start a process instance
String procId = runtimeService.startProcessInstanceByKey("financialReport").getId();
// Get the first task
TaskService taskService = processEngine.getTaskService();
List<Task> tasks = taskService.createTaskQuery().taskCandidateGroup("accountancy").list();
for (Task task : tasks) {
System.out.println("Following task is available for accountancy group: " + task.getName());
// claim it
taskService.claim(task.getId(), "fozzie");
}
// Verify Fozzie can now retrieve the task
tasks = taskService.createTaskQuery().taskAssignee("fozzie").list();
for (Task task : tasks) {
System.out.println("Task for fozzie: " + task.getName());
// Complete the task
taskService.complete(task.getId());
}
System.out.println("Number of tasks for fozzie: "
+ taskService.createTaskQuery().taskAssignee("fozzie").count());
// Retrieve and claim the second task
tasks = taskService.createTaskQuery().taskCandidateGroup("management").list();
for (Task task : tasks) {
System.out.println("Following task is available for management group: " + task.getName());
taskService.claim(task.getId(), "kermit");
}
// Completing the second task ends the process
for (Task task : tasks) {
taskService.complete(task.getId());
}
// verify that the process is actually finished
HistoryService historyService = processEngine.getHistoryService();
HistoricProcessInstance historicProcessInstance =
historyService.createHistoricProcessInstanceQuery().processInstanceId(procId).singleResult();
System.out.println("Process instance end time: " + historicProcessInstance.getEndTime());
}
}
7.3.12 미래 강화
It’s easy to see that this business process is too simple to be usable in reality. However, as you are going through the BPMN 2.0 constructs available in Flowable, you will be able to enhance the business process by:
이 업무 절 차 는 너무 간단 해서 실제 적 으로 사용 할 수 없다 는 것 을 쉽게 알 수 있다.단, Flowable 에서 사용 할 수 있 는 BPMN 2.0 구 조 를 알 게 되면 다음 과 같은 방식 으로 업무 절 차 를 강화 할 수 있 습 니 다.
이 내용에 흥미가 있습니까?
현재 기사가 여러분의 문제를 해결하지 못하는 경우 AI 엔진은 머신러닝 분석(스마트 모델이 방금 만들어져 부정확한 경우가 있을 수 있음)을 통해 가장 유사한 기사를 추천합니다:
Flowable 6.6.0 BPMN 사용자 가이드 - 9 폼 - 9.1 폼 정의외부 폼 표시 정책 에 대해 서 는 폼 속성 (버 전 5 의 Explorer 웹 응용 프로그램 에서 지원) 을 사용 할 수 있 습 니 다.또한 폼 키 정의 (formkey definition) 를 사용 할 수 있 습...
텍스트를 자유롭게 공유하거나 복사할 수 있습니다.하지만 이 문서의 URL은 참조 URL로 남겨 두십시오.
CC BY-SA 2.5, CC BY-SA 3.0 및 CC BY-SA 4.0에 따라 라이센스가 부여됩니다.