/** * Get all paths for the specified workflow instance */ public Scriptable getPaths() { WorkflowService workflowService = serviceRegistry.getWorkflowService(); List<WorkflowPath> cmrPaths = workflowService.getWorkflowPaths(this.id); ArrayList<Serializable> paths = new ArrayList<Serializable>(); for (WorkflowPath cmrPath : cmrPaths) { paths.add(new JscriptWorkflowPath(cmrPath, this.serviceRegistry, this.scope)); } Scriptable pathsScriptable = (Scriptable)new ValueConverter().convertValueForScript(this.serviceRegistry, this.scope, null, paths); return pathsScriptable; }
/** * Get all paths for the specified workflow instance */ public Scriptable getPaths() { WorkflowService workflowService = serviceRegistry.getWorkflowService(); List<WorkflowPath> cmrPaths = workflowService.getWorkflowPaths(this.id); ArrayList<Serializable> paths = new ArrayList<Serializable>(); for (WorkflowPath cmrPath : cmrPaths) { paths.add(new JscriptWorkflowPath(cmrPath, this.serviceRegistry, this.scope)); } Scriptable pathsScriptable = (Scriptable)new ValueConverter().convertValueForScript(this.serviceRegistry, this.scope, null, paths); return pathsScriptable; }
/** * Nominated invites workflows finish without waiting for user accept */ @Test public void testWorkflowTaskContainsProps() { Invitation.ResourceType resourceType = Invitation.ResourceType.WEB_SITE; String resourceName = SITE_SHORT_NAME_INVITE; String inviteeRole = SiteModel.SITE_COLLABORATOR; String serverPath = "wibble"; String acceptUrl = "froob"; String rejectUrl = "marshmallow"; NominatedInvitation nomInvite = invitationService.inviteNominated(USER_ONE, resourceType, resourceName, inviteeRole, serverPath, acceptUrl, rejectUrl); List<WorkflowPath> paths = workflowService.getWorkflowPaths(nomInvite.getInviteId()); assertEquals(0, paths.size()); }
List<WorkflowPath> paths = workflowService.getWorkflowPaths(workflowId); for (WorkflowPath path : paths) List<WorkflowPath> paths = workflowService.getWorkflowPaths(workflowId); if (paths.size() == 0) currentPath = workflowService.getWorkflowPaths(instance.getId()).get(0); out.print(executeCommand("use"));
List<WorkflowPath> paths = workflowService.getWorkflowPaths(workflowId); for (WorkflowPath path : paths) List<WorkflowPath> paths = workflowService.getWorkflowPaths(workflowId); if (paths.size() == 0) currentPath = workflowService.getWorkflowPaths(instance.getId()).get(0); out.print(executeCommand("use"));
workflowService.endTask(startTask.getId(), null); List<WorkflowPath> paths = workflowService.getWorkflowPaths(instanceId); assertEquals(1, paths.size()); path = paths.get(0);
WorkflowPath path = workflowService.getWorkflowPaths(taskAssigneeWorkflowInstance.getId()).get(0);
List<WorkflowPath> paths = workflowService.getWorkflowPaths(workflowInstanceId); assertNotNull(paths); assertEquals(1, paths.size());
List<WorkflowPath> paths = workflowService.getWorkflowPaths(workflowInstanceId); assertNotNull(paths); assertEquals(1, paths.size());