This documentation relates to the 5.2 release of Comala Workflows

 Documentation for other versions of Comala Workflows is available too.

Overview

The {set-state} macro is used to immediately transition to a designated state – either on the current page, parent page or child pages – regardless of how transition to that state would normally occur.

Where to use it?

Optional.

One {set-state} macro can be put in a {trigger} macro.

Parameters

Parameter

Required

Default

Notes

Ver

unnamed first parameter
or state

(tick)

 

The state to transition to.

Note: It must be defined in the workflow.


comment


 

Comment to associate with the state change:

  • Plain text
  • Cn use any character set supported by your Confluence server – except some reserved characters.

draft or
draftspace


false

UNDER REVIEW We are currently reviewing these parameters AWP-3764

See also: Publishing

3.0.4+

page


 current page

If specified, the state will be changed on the parent page or child pages, not the current page:

  • @parent – Change state of parent page
  • @children – Change state of child pages

Obviously, this parameter only works on pages, not blog posts.


Events

The following Events are associated with state transitions:

  • statechanged
  • pagestatechanged
  • newsstatechanged

Example

In this example, entering state B causes an immediate transition to state C.

{workflow:Instant transition}
   {state:A|submit=B}
   {state}
   {state:B}
   {state}
   {state:C}
   {state}
   {trigger:statechanged|state=B}
      {set-state:C}
   {trigger}
{workflow}

All examples

There is no content with the specified labels

See also

Workflow Authoring Guide: