10.4.3. Defining and Editing Lifecycle Transitions

Engineering Knowledge Manager

Administration Guide | Chapter 10: Defining and Configuring Lifecycles | 10.4. Defining Lifecycles in EKM Studio |

10.4.2. Defining and Editing Lifecycle Stages |  | 10.4.4. Saving Lifecycle Files
Prev |  | Next

### 10.4.3. Defining and Editing Lifecycle Transitions

Actions that are associated with lifecycle transitions are presented in the following sections.

Topics in this section include:

- Inserting New Transitions

- Editing Transitions

- Deleting Transitions

#### 10.4.3.1. Inserting New Transitions

You can add a transition between any two stages in a lifecycle diagram by selecting the stages you want to connect and clicking on the toolbar.

#### 10.4.3.2. Editing Transitions

Once you have inserted a transition in a lifecycle diagram you can set up macros for promoting and demoting objects, and define Promote and Demote signoff processes.

To edit a transition:

1. Double-click the transition in the lifecycle diagram, or right-click the transition in the diagram or tree and select Edit from the context menu. The Edit Transition dialog box will appear.

   Figure 10.3: Edit Transition Dialog Box for a Lifecycle

2. Specify any macros that are to be used for performing actions associated with promote/demote requests. The types of macros that you can specify are described below. See Using Macros in Lifecycle Definitions for details on how to define macros.

   Promote validation macro

     The name of the macro that is used to perform validation before a promote request can be processed.

   Promote action macro

     The name of the macro that is used to perform an automatic action after a promotion request has been processed.

   Demote validation macro

     The name of the macro that is used to perform validation before a demote request can be processed.

   Demote action macro

     The name of the macro that is used to perform an automatic action after a demote request has been processed.

3. Define the signoff processes for promoting and demoting the object. Only the person who created the process can promote it. You can create a multi-level signoff process by adding any number of signoff elements to the Promote signoff or Demote signoff window pane. In the example shown in Figure 10.3: Edit Transition Dialog Box for a Lifecycle, there are two levels of signoff defined for stage promotion: `Level 1` is required by all members of the `Design Team`; and `Level 2` by the `Development Manager`. The first level must be completed before the next one can begin.

   Click Insert to add rows to the Promote signoff or Demote signoff table. To remove a row, select it and click Delete. Once an entry has been added to a table, you can define its properties:

   - Level: Specifies the name of signoff level. There are no character restrictions for the level definition. Double-click in the Level text box to enter/edit the name.

   - Members: Specifies the names of users and groups who are involved in the signoff at this level. If you specify more than one user or group, you will need to separate their names by a comma. Single-click in the Members box and a drop-down list of available members will be displayed (drop-down list not shown in Figure 10.3: Edit Transition Dialog Box for a Lifecycle).

   - Inclusive: Specifies whether or not all Members for this level need to approve the signoff. If the Inclusive box is checked, then ALL Members must approve the signoff. If it is cleared, then any member can approve the level signoff.

   - Due Days Specifies the number of days allowed for the signoff. If a user has not approved or a rejected the signoff by then, a daily reminder mail is sent to the user. Double-click in the Due Days box to enter/edit the amount of time the Members have to complete the signoff process.

4. Click OK to save your changes.

#### 10.4.3.3. Using Macros in Lifecycle Definitions

You can define macros in EKM Studio and embed them in a lifecycle definition to automate certain tasks.

You can specify a macro in a transition to:

- Perform validations before promoting or demoting a stage.

- Execute automated tasks after promotion or demotion.

- Dynamically assign users and groups to a signoff request in a lifecycle.

To define a macro, select Edit > Script, then type your script in the Edit Script dialog box. Note that you do not insert the `<script>` tag in the macro definition; this is added automatically by EKM Studio.

You should define the macro using the scripting language (Python or Beanshell) displayed above the editing window. The scripting language for a lifecycle is set in your lifecycle attributes.

The example below shows the script for a BeanShell macro named `solveOnce`.

Figure 10.4: Edit Script Dialog Box

The name that you define for the macro in the script can then be entered in the Edit Transition dialog box so that it can be utilized.

Note: Jython imposes a limit of 100 KB per script file. To avoid lifecycle errors it is recommended that you create scripts using the EKM scripting interface and store them in the Scripts folder on the Administration/Configuration page. For details see Using EKM's Scripting Interface. Storing scripts in a centralized library makes them available for any process template, lifecycle, or custom type. See Configuring a Common Scripts Library for details.

#### 10.4.3.4. Deleting Transitions

To delete a transition in a lifecycle diagram, right-click the transition in the diagram or in the tree and select Delete from the context menu. You can also delete a transition by selecting it in the diagram and pressing the Delete key on your keyboard.

Contains proprietary and confidential information of ANSYS, Inc. and its subsidiaries and affiliates.

Prev | Up / Contents | Next

Release 18.2 - © ANSYS, Inc. All rights reserved.