Difference between revisions of "GetWorkflowActionList"
From LongJump Support Wiki
imported>Aeric |
imported>Aeric |
||
Line 1: | Line 1: | ||
{{DISPLAYTITLE:getWorkflowActionList}} | {{DISPLAYTITLE:getWorkflowActionList}} | ||
Retrieves a list of [[Workflows# | Retrieves a list of [[Workflows#Workflow Actions|Workflow Actions]] available for a record, depending on it's [[Workflows#Workflow States|Workflow State]]<noinclude>, via the [[Java API]]</noinclude>. | ||
;Syntax: | ;Syntax: |
Latest revision as of 21:05, 23 November 2011
Retrieves a list of Workflow Actions available for a record, depending on it's Workflow State, via the Java API.
- Syntax
Functions.getWorkflowActionList(String objectName,String recordId)
- where:
- objectName is the name or id of the object
- recordId is the id of the record
- Return
- Map
- Example
- This example returns workflow action list for object "Invoice". A map of actions for a record in the Invoice object is returned.
Functions.debug("Retrieve workflow action list"); String recordId = requestParams.get("record_id"); Map<String,WorkflowActionBean> wfCollection = Functions.getWorkflowActionList("Invoice", recordId); for(Map.Entry<String,WorkflowActionBean> e : wfCollection.entrySet()) { WorkflowActionBean wf = e.getValue(); Functions.debug("Action name : "+ wf.getName()); }