Skip to main content

FieldLogs

Component
Component.png

The Component element enables you to embed a different Template within the current Template.

To create a Component:

  1. Click or drag the Component element from the element panel.

    component1.png
  2. A blank Component element appears in the workspace pane.

    component2.png

In the Step Information Editor, select the Template that needs to be embedded as the Component. You can filter the results from the list of available Templates.

SIE.png

Select the required Template from the list.

Required_template.png

The selected Template is embedded in the Component.

Select Only Published option, to view the Published Templates.

Only_Published.png

Select Show all option, to view all the Templates (both Published and Private).

Show_all_option.png

The name of the selected Template appears in the Component element.

You can View/Hide the Component element. Refer here for more details.

The Component element has two additional options:

  1. Target Version

  2. Behaviour

The Target version option is available when a published Template is selected to be embedded as a component. Select the version of the Template from the dropdown list.

target_version.png

The Behavior determines how the embedded Template is executed at run time.

There are four options available as shown below:

behavior_option.png
  1. Replace on Run: The component template is launched at the same level as the main template.

  2. Partial replace on Run: Select some steps of the selected Component Template

  3. Insert on validate: The embedded Component template is launched as the child Step

  4. Partial insert on Validate: Selected steps of the template are launched as a child Step.

Replace on Run: The Behavior option can be set to Replace On Run. This option causes the embedded Component Template to be launched at the same level as the main Template Steps. The Steps of the Component will be executed as individual Steps and not as Child Steps.

Replace_on_Run_.png

Partial Replace on Run: The Behavior option can be set to Partial Replace on Run. This option allows the user to select some steps of the Template.

Shown below is an example of the Steps in the Component Template.

Steps_in_Embedded_Component.png

Select the Behaviour option as Partial Replace on Run.

partial_replace_on_run.png

Select part of the Component Template as shown in the example below.

partial_replace_on_run_steps.png

Click again on the Step, If you need to remove a step from the selection.

Click Clear button, to clear all the selected Steps and include all the Steps of the Component.

click_clear_.png

Important

1. When a Child Step is selected corresponding Parent Step is also selected.

2. When a Parent Step is selected the associated child Step(s) are selected.

The selected Steps are displayed in the work card view and the Execution Preview of the Template as shown below.

view_of_the_component_template.png

During runtime, only the selected Steps for the Behaviour Partial Replace on Run are executed.

execution_partial_replace_on_run.png

Insert on Validate: This option causes the embedded Template to be run as a child Step.

When selecting this option, a text box Insert On Validate text appears. Checking the HTML option enables advanced text formatting capabilities.

HTML.png

The text entered appears on the Component Step as shown.

text_insert_on_validate.png

At run time, a button Execute Template is displayed on the Step.

execute_template.png

Click Execute Template . The embedded Template is launched as a child Step. The Steps of the Embedded Component are displayed as the Child Steps of the main Template.

embedded_template_as_child.png

Partial Insert on Validate : This option causes the selected section of the Template to be run as a child Step of the Template.

behavior_partial_insert_on_validate.png

Select part of the Component Template as shown in the example below.

Selected_Steps_for_Partial_insert_on_Validate.png

Click Execute Template to execute the Steps selected from the Component.

execute_template_partial_insert_on_validate.png

During runtime, only the selected Steps for the Behaviour Partial Insert on Validate are executed.

partial_Insert_on_validate_-_execution.png

Note

Execute Template is a button that appears when Behavior is selected as Insert on Validate or Partial Insert on Validate.

There are some features that can be performed on the Component. All the features are explained here.

Only Templates can be child Steps of a Component.

Note

You cannot link a part of a Template to a Component.

Warning

Using only the Published Template embedded within a Component element is recommended. A Template with an empty Component element cannot be saved.