\WorkflowService
A central point for interacting with workflows
- Author: marcus@silverstripe.com.au
- License: BSD License (http://silverstripe.org/bsd-license/)
Synopsis
class WorkflowService
implements
PermissionProvider
{
- // members
- protected $templates;
- // methods
- public void __construct()
- public void setTemplates()
- public type getTemplates()
- public WorkflowTemplate getNamedTemplate()
- public void getDefinitionFor()
- public WorkflowInstance getWorkflowFor()
- public DataObjectSet getWorkflowHistoryFor()
- public DataList getDefinitions()
- public void executeTransition()
- public void startWorkflow()
- public ArrayList usersWorkflows()
- public DataList userPendingItems()
- public DataList userSubmittedItems()
- public void defineFromTemplate()
- public void reorder()
- public array providePermissions()
Hierarchy
Implements
- PermissionProvider
Members
protected
- $templates
—
array
An array of templates that we can create from
Methods
public
- __construct()
- defineFromTemplate() — Generate a workflow definition based on a template
- executeTransition() — Given a transition ID, figure out what should happen to the given $subject.
- getDefinitionFor() — Gets the workflow definition for a given dataobject, if there is one
- getDefinitions() — Get all the available workflow definitions
- getNamedTemplate() — Get a template by name
- getTemplates() — Return the list of available templates
- getWorkflowFor() — Gets the workflow for the given item
- getWorkflowHistoryFor() — Get all the workflow action instances for an item
- providePermissions()
- reorder() — Reorders actions within a definition
- setTemplates() — Set the list of templates that can be created
- startWorkflow() — Starts the workflow for the given data object, assuming it or a parent has a definition specified.
- userPendingItems() — Get items that the passed-in user has awaiting for them to action
- userSubmittedItems() — Get items that the passed-in user has submitted for workflow review
- usersWorkflows() — Get all the workflows that this user is responsible for