What is an Embedded Actionflow?
Embedding Actionflows allows an An action node or group of action nodes to can be nested within an
Insert excerpt |
---|
| _actionflow |
---|
| _actionflow |
---|
nopanel | true |
---|
|
node that can be reused without reusing the entire Actionflow
, for . For example, a Calculate Action that normalises an area code can be extracted from its original Actionflow and reused
(embedded) within many other Actionflows
by embedding using
an its Insert excerpt |
---|
| _actionflow |
---|
| _actionflow |
---|
nopanel | true |
---|
|
node.
For reusing entire Actionflows, see 1.17 see Instances and Reusability. For extracting or moving an action(s) to another Actionflow, see 2.13 see Extracting and Moving Actions.
Note |
---|
title | Embedding Compatibility |
---|
|
When an attempt is made to embed an actionflow a number of checks should be made The actionflow must not have phases or start phase nodes, confirmation dialogs That no embedding loops are created (A embedding B, which embeds C which embeds A A recursive check is made, at the minimum checking on descendants don’t embed A (as existing loops should have previously been prevented, but better to keep track of the layers in case you encounter A->B->C->B..
An actionflow in an app can’t be embedded in a package
An error plink will be displayed if the embedded Actionflow is incompatible (e.g. has phases, confirmation dialogs). When editing an action flow which has been embedded it will prevent the creation of phases etc. |
For the full list of Actionflow node Insert excerpt |
---|
| _property_settings |
---|
| _property_settings |
---|
nopanel | true |
---|
|
, see Actionflow Action Properties.
Embedding Actionflows
An action(s) can be embedded by after using the
Insert excerpt |
---|
| _extract_actionflow |
---|
| _extract_actionflow |
---|
nopanel | true |
---|
|
option option, see
2.13 Extracting and Moving Actions, or by opening the list of Actionflows in the
Repository and dragging Insert excerpt |
---|
| _repository |
---|
| _repository |
---|
nopanel | true |
---|
|
and dragging one onto the canvas.
- Click the
Insert excerpt |
---|
| _actionflow |
---|
| _actionflow |
---|
nopanel | true |
---|
|
option in the toolbar - Drag and drop an Actionflow from an
Insert excerpt |
---|
| _actionflow |
---|
| _actionflow |
---|
nopanel | true |
---|
|
from the Repository onto the canvas - An embedded Actionflow
Insert excerpt |
---|
| _actionflow |
---|
| _actionflow |
---|
nopanel | true |
---|
|
node is created- If any edits changes are required to the functionality within the embedded Actionflow, right-click on the embedded node and choose
Insert excerpt |
---|
| _actionflow_icon |
---|
| _actionflow_icon |
---|
nopanel | true |
---|
|
Display
Note |
---|
title | Embedding Compatibility |
---|
|
- Actionflows containing
Insert excerpt |
---|
| _action_phase |
---|
| _action_phase |
---|
nopanel | true |
---|
| s, Insert excerpt |
---|
| _action_phase |
---|
| _action_phase |
---|
name | start |
---|
nopanel | true |
---|
| actions, and confirmation screens cannot be embedded - When editing an Actionflow that has been embedded,
Insert excerpt |
---|
| _action_phase |
---|
| _action_phase |
---|
nopanel | true |
---|
| s cannot be created - An Actionflow in an application cannot be embedded in a package
|
HTML Comment |
---|
|
Insert excerpt |
---|
| Actionflow NodeAction Properties |
---|
| Actionflow NodeAction Properties |
---|
nopanel | true |
---|
|
|
Worked Example
Here's a worked example using the Shop the Retail Data (available from the Learning Centre).
In this example, we are using:
- A 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 completed Extracting and Moving Actions, expand the section below and follow the steps to create an extracted Actionflow.
.
Expand |
---|
title | Create an Extracted Actionflow |
---|
|
Insert excerpt |
---|
| 2.13 Extracting and Moving Actions to a New Actionflow2.13 |
---|
| Extracting Actions to a New Actionflowand Moving Actions |
---|
name | extract |
---|
nopanel | true |
---|
|
|
.
Embed Proper Case Actionflow
In this example, we'll embed an extracted action node that converts a string entered for a First Name attribute First Name string to proper case. We'll embed this within the Save action on the Staff Form.
Image Added
- Open the Actionflow on the Save button on the Staff Form
- Click
Insert excerpt |
---|
| _actionflow |
---|
| _actionflow |
---|
nopanel | true |
---|
|
in the toolbar and drag the Proper Case Actionflow from the Insert excerpt |
---|
| _repository |
---|
| _repository |
---|
nopanel | true |
---|
|
Drag it onto the canvas - Click and drag
Insert excerpt |
---|
| _actionflow |
---|
| _actionflow |
---|
nopanel | true |
---|
|
node onto the connector between the and Save action and Insert excerpt |
---|
| _action_gateway |
---|
| _action_gateway |
---|
nopanel | true |
---|
|
action and drop it when the Insert excerpt |
---|
| _add_icon |
---|
| _add_icon |
---|
nopanel | true |
---|
|
icon appears - Choose the out_ProperCase connection point from the Select Connection Point pop up
- Click on the connector between the Proper Case and Save actionMap input and embedded node and map across the attribute first_name
- Click on both connectors between the
Insert excerpt |
---|
| _action_gateway |
---|
| _action_gateway |
---|
nopanel | true |
---|
|
node and Insert excerpt |
---|
| _action_save |
---|
| _action_save |
---|
nopanel | true |
---|
|
actionsOn both connectors, map across the ProperCase attribute from the
embedded action node to the firstName attribute on the Save action
1.02 Actionflow Principlesembedded
Insert excerpt |
---|
| _actionflow |
---|
| _actionflow |
---|
nopanel | true |
---|
|
node to the first_name attribute on the table
Checkpoint
Image Added
Testing
- To test the Actionflow, open the Shop Staff screen
- Select an existing staff member from the grid and press Edit
- Change their first name to be in capitals and click Save
- You should see on the Staff grid that their first name has saved in proper case
Image Added