If you're using Comala Workflows to add workflows to your pages, you can use multiple placeholders to refer to specific Comala Workflows status information of your root page or the workflow assigned to it.

All following placeholder refer to the root page of the export (the page the export was started from). Currently it is not possible to have running elements.

However, this requirement is already tracked in our JIRA system: EXP-354 - Getting issue details... STATUS

Please sign up at https://k15t.jira.com/secure/Signup!default.jspa to watch, comment on or vote for this issue. You'll then get a notification for every status update on the issue.

Available placeholders for the page status

For the page state the following placeholders are available:

PlaceholderTypeDescription
$currentState.Name
String

The name of the current state of the page.

(info) This placeholder returns the same value as $adhocState.

$currentState.Description
StringThe description of the current state of the page.
$currentState.ContentVersion
IntegerThe page revision that the state refers to.
$currentState.Published
Boolean

Returns true if the page is in public status.

$currentState.UserName
String

The name of the user who assigned the current status.

$currentState.Date
java.util.Date

The timestamp of the date the page got the current state.

$currentState.Comment
StringThe note inserted on the status change.

(info) The placeholders must  be defined in your template using Velocity.

For example:

Returns the user name of the Confluence user who assigned the current state to the page

#set($currentState = ${workflowsHelper.stateForPage($page.Id)})
#if ($currentState)
    $currentState.UserName
#end
CODE

If you want to refer to the last published state, you have to change your variable:

Returns the user name of the Confluence user who assigned the last published state to the page

#set($publishedState = ${workflowsHelper.stateForPage($page.Id, true)})
#if ($publishedState)
    $currentState.UserName
#end
CODE

If you've defined to only export pages in Comala Workflow status Publish:

Returns the user name of the Confluence user who assigned the state to the last published page

#set($state = ${workflowsHelper.stateForPage($page.Id, $isPublishedOnly)})
#if ($publishedState)
    $currentState.UserName
#end
CODE

Available placeholders for the workflow

Besides page specific information you can also use workflow specific placeholders:

PlaceholderTypeDescription
$workflow.Name
StringThe name of the current workflow.
$workflow.Description
StringThe description of the current workflow.
$workflow.LabelName
String 
$workflow.Active
Boolean Returns true if the workflow is active.

(info) The placeholders must  be defined in your template using Velocity.

For example

Returns the description of the current workflow

#set($workflow = ${workflowsHelper.workflowForPage($pageId)})
#if ($workflow)
    $workflow.Description
#end
CODE

If you want to refer to the active workflow:

Returns the description of the current active workflow

#set($workflows = ${workflowsHelper.activeWorkflowsForPage($page.Id)})
#foreach($workflow in $workflows)
    $workflow.Description
#end
CODE