Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Insert excerpt
_Banners
_Banners
nameactionflow
nopaneltrue

What is an Embedded Actionflow?

An action node or group of action nodes can be nested within an

Insert excerpt
_actionflow
_actionflow
nopaneltrue
 node that can be reused without reusing the entire Actionflow. For example, a Calculate Action that normalises an area code can be extracted from its original Actionflow and reused (embedded) within many other Actionflows using its 
Insert excerpt
_actionflow
_actionflow
nopaneltrue
 node.                         

For reusing entire Actionflows, see 1.17 Instances and Reusability. For extracting or moving an action(s) to another Actionflow, see 2.13 06 Extracting and Moving Actions.

Embedding Actionflows

An action(s) can be embedded after using the 

Insert excerpt
_extract_actionflow
_extract_actionflow
nopaneltrue
 option,  see 2.13 06 Extracting and Moving Actions, or by opening the list of Actionflows in the
Insert excerpt
_repository
_repository
nopaneltrue
 and dragging one onto the canvas.

  1. Click the
    Insert excerpt
    _actionflow
    _actionflow
    nopaneltrue
     option in the toolbar
  2. Drag and drop an 
    Insert excerpt
    _actionflow
    _actionflow
    nopaneltrue
     from the Repository onto the canvas
  3. An embedded
    Insert excerpt
    _actionflow
    _actionflow
    nopaneltrue
     node is created
    1. If any changes are required to the functionality within the embedded Actionflow, right-click on the embedded node and choose
      Insert excerpt
      _actionflow_icon
      _actionflow_icon
      nopaneltrue
       Display
Note
titleEmbedding Compatibility
  • Actionflows containing 
    Insert excerpt
    _action_phase
    _action_phase
    nopaneltrue
    s,
    Insert excerpt
    _action_phase
    _action_phase
    namestart
    nopaneltrue
     actions, and confirmation screens cannot be embedded
  • When editing an Actionflow that has been embedded,
    Insert excerpt
    _action_phase
    _action_phase
    nopaneltrue
    s cannot be created
  • An Actionflow in an application cannot be embedded in a package


HTML Comment
hiddentrue

Insert excerpt
Actionflow Node
Actionflow Node
nopaneltrue

Worked Example

Here's a worked example using the Shop the Retail Data (available from the Learning Centre).

In this example, we are using:  

  • Staff Form screen containing blank input fields, set up to create a new staff member  - this screen was created using the Edit Form template
Tip

If you are completing this chapter as part of the Actionflow course and using a training instance, the data and screens have already been pre-loaded into the Actionflow Intermediate Application. For this example, we'll be working on the Save button on the Staff Form screen.

GIF/SCREENSHOT OF FINISHED RESULT

Prerequisites 

For this example, we'll embed an extracted Actionflow. If you have not completed 2.13 06 Extracting and Moving Actions, expand the section below and follow the steps to create an extracted Actionflow.

.

Expand
titleCreate an Extracted Actionflow

Insert excerpt
2.13 06 Extracting and Moving Actions
2.13 06 Extracting and Moving Actions
nameextract
nopaneltrue

.

Embed Proper Case Actionflow

In this example, we'll embed an extracted action node that converts a First Name string to proper case. We'll embed this within the Save action on the Staff Form.

Image Added

Embed Extracted Action in Actionflow

  1. Open the Actionflow on the Save button on the Staff Form
  2. Click 
    Insert excerpt
    _actionflow
    _actionflow
    nopaneltrue
     in the toolbar and drag the Proper Case Actionflow from the
    Insert excerpt
    _repository
    _repository
    nopaneltrue
     onto the canvas
  3. Click and drag 
    Insert excerpt
    _actionflow
    _actionflow
    nopaneltrue
     node onto the connector between the
    Insert excerpt
    _input
    _input
    nopaneltrue
     and
    Insert excerpt
    _action_savegateway
    _action_savegateway
    nopaneltrue
     action and drop it when the 
    Insert excerpt
    _add_icon
    _add_icon
    nopaneltrue
     icon appears
  4. Choose the out_ProperCase connection point from the Select Connection Point pop up
  5. Click on the connector between the Proper Case  input and embedded node and map across the attribute first_name
  6. Click on both connectors between the
    Insert excerpt
    _actionflowaction_gateway
    _actionflowaction_gateway
    nopaneltrue
     
    node and 
    Insert excerpt
    _action_save
    _action_save
    nopaneltrue
     actionMap  actions
    1. On both connectors, map across the ProperCase attribute from the embedded 

      Insert excerpt
      _actionflow
      _actionflow
      nopaneltrue
       node to the first_name attribute on

    the  Insert excerpt_action_save_action_savenopaneltrue action 
    1. the table

      Expand
      titleCheckpoint

      Image Added


Testing

  1. To test the Actionflow, open the Shop Staff screen
  2. Select an existing staff member from the grid and press Edit
  3. Change their first name to be in capitals and click Save
  4. You should see on the Staff grid that their first name has saved in proper case


Image Modified