Module: alfresco/forms/controls/Transitions

alfresco/forms/controls/Transitions

This module has been provided to support the FormsRuntimeService to address the requirements of rendering buttons for each transition available when editing a workflow task.
Since:
  • 1.0.86
Author:
  • Dave Draper
License:
Source:

Members

transitionButtonsUpdateTopic :string

This will be set to a generated topic that is published when a value is set and is subscribed to by a DynamicWidgets. The payload is a widgets model containing a button for each transition available.
Type:
  • string
Default Value:
  • null
Source:

transitionTopic :string

This will be set to a generated topic that is published whenever a user makes a transition. The transition will be handled by onTransition.
Type:
  • string
Default Value:
  • null
Source:

transitionValue :string

This will be set by onTransition whenever a user makes a transition and will be returned by getValue.
Type:
  • string
Default Value:
  • null
Source:

Methods

createFormControl()

Creates a new DynamicWidgets that is used to render buttons for each transition available.
Source:

getValue() → {string}

Overrides the inherited function to return transitionValue.
Source:
Returns:
Returns the transition (if one has been made)
Type
string

onTransition()

Handles the user making a transition. The transition value is updated and a topic is published to request that the [form]{@link module:alfresco/forms/Form} be submitted.
Source:
Fires:

postCreate()

Generates the transitionTopic and transitionButtonsUpdateTopic and then sets up the subscription to handle transitions being made.
Source:

setTransitions(value)

Processes the supplied value to derive transitions and then publishes a request to render each transition as a button.
Parameters:
Name Type Description
value string The value to derive transitions from.
Source:

setupChangeEvents()

Overrides the inherited function to intentionally do nothing.
Source:

setValue(value)

Calls setTransitions to process the transition data render buttons for each transition available.
Parameters:
Name Type Description
value object The value to set.
Source: