Overview
The Handy app status macro adds and removes the labels on the page.
When a Comala Document Management workflow trigger is configured to listen to labeladded
and pageupdated
events, the Handy Status and the workflow status can be set to "synchronize" when using the StiltSoft Handy Macros for Confluence app.
You need the Handy Macro app v3.8.0 or above.
The scenario
A user can change the Handy Status value and use this to update the Comala Document Management workflow state.
The Handy Status macro must be configured to be linked to the page label. When the Handy Status macro Synchronize the page label with status option is checked
the page label is updated every time you switch the status
It is configured when you insert the Handy Status macro or edit the macro settings.
For further information refer to the Handy Macro app product documentation - https://docs.stiltsoft.com/hmfc/server-dc/handy-status/how-to-use-handy-status#HowtouseHandyStatus-Linkthestatustothepagelabel.
The solution
In a simple example
the Handy status macro is synchronized to change the label for the content
the Handy status is either no or yes
A Comala Document Management workflow is applied (with two states, In Progress and Approved), and includes two separate triggers to change the workflow state when the page label is changed in sync with the Handy Status. A third trigger is included and is used to change the page label when the page is edited in the Approved state
Workflow trigger one - Handy status changed to “no”
Handy status is changed to no
the label no is added to the page
a workflow trigger listening for the addition of label no sets the state to the In Progress state
{trigger:labeladded|label=no} {set-state:In Progress} {trigger}
Workflow trigger two - Handy status changed to “yes”
Handy status is changed to yes
the label yes is added to the page
a workflow trigger listening for the addition of the label yes sets the state to the Approved state
Workflow trigger three - page update in the Approved state changes page label
A third workflow trigger manages the response to a page being edited and updated in the Approved state.
An updated state transition is not added to the Approved state. The transition is managed by this workflow trigger.
The workflow trigger listens for the pageupdated
event when the workflow is in the Approved state. On this pageupdated
event, the trigger
changes the state to the In Progress state
sets the page label to no
removes the page label yes
The Handy Status is synchronized with the page label so its status changes to no - the new page label value updated by the workflow trigger.
To prevent large numbers of notifications to page watchers, the Handy Macro app marks its content updates as "Minor change" (the same as if you clear the "Notify Watchers" checkbox while editing a page). With triggers and conditions, we can filter out "Minor Change" events and then use an action macro in the trigger to transition the state.
Workflow triggers
{trigger:labeladded|label=no} {set-state:In Progress} {trigger} {trigger:labeladded|label=yes} {set-state:Approved} {trigger} {trigger:pageupdated|state=Approved|isminorchange=true} {set-state:In Progress} {set-label:no} {remove-label:yes} {trigger}
The isminorchange
parameter is a workflow condition that can be used in a pageupdated
or newsupdated
workflow trigger with the StiltSoft Handy Macros app.
App configuration
There is also a Document Management app setting which may be affected by the Handy app macro updating content...
Setting | Where | Notes |
---|---|---|
Page Update Reset Approval | If enabled, content updates will reset any approvals in an active content review. |