use of io.crnk.activiti.example.approval.ApprovalRelationshipRepository in project crnk-framework by crnk-project.
the class ApprovalTestApplication method createApprovalModule.
// tag::approvalModule[]
public static SimpleModule createApprovalModule(ApprovalManager approvalManager) {
FilterSpec approvalFilter = new FilterSpec(Arrays.asList("definitionKey"), FilterOperator.EQ, "scheduleChange");
List<FilterSpec> approvalFilters = Arrays.asList(approvalFilter);
SimpleModule module = new SimpleModule("approval");
module.addRepositoryDecoratorFactory(ApprovalRepositoryDecorator.createFactory(approvalManager));
module.addRepository(new ApprovalRelationshipRepository(Schedule.class, ScheduleApprovalProcessInstance.class, "approval", "approval/schedule", approvalFilters));
return module;
}
Aggregations