Documentation Index

Fetch the complete documentation index at: https://docs.staedean.com/llms.txt

Use this file to discover all available pages before exploring further.

Set up Lifecycle actions

Prev Next

The Lifecycle actions table stores actions for a Lifecycle state or a Lifecycle state transition. Action handlers extend the Lifecycle framework. A state transition uses these action handlers to perform actions. You can pass arguments to an action handler. For example, the action handler for posting sales documents can have two arguments: post and ship.

Lifecycle actions apply on two levels:

  • The Lifecycle state - Lifecycle state actions always apply.

  • The Lifecycle state transition - Lifecycle state transition actions apply only to the specific transitions (From State; To State).

Lifecycle state actions always apply to the state. You do not need to repeat them in the Lifecycle Transition Actions.

To set up Lifecycle state actions

  1. From the Lifecycle Card, select States.

  2. On the Lifecycle States page, select a state and select Actions.

  3. On the Lifecycle Actions page, select New and fill in the fields:

To set up Lifecycle state transition actions

  1. From the Lifecycle Card, select the Lifecycle line.

  2. Select Line/Actions.

  3. On the Lifecycle Actions page, select New and fill in the fields:

Field

M

Description

Type

Select the type of Lifecycle state transition trigger. The following types are available: On Status Change - triggers the action during the transition from state to the To state; After Status Change - triggers the action when in the To state.

Action Handler Name*

Select an available action from the list. These actions come from a specific code unit.

Argument

When the action requires arguments, a Boolean appears. Set the arguments in the Arguments page through Related Information > Action > Arguments.

Batch Processing*

Use this function to submit specific tasks for background processing. When a Job Queue entry is created for the Lifecycle Instance, the Job Queue processes the specified action. A Microsoft Dynamics 365 Business Central Application Server (NAS) running the Job Queue parameter is required. The Lifecycle Instance submitted has the status Pending until it completes or fails, based on the processing policy.

Processing Policy*

These settings apply to batch processing: Stop and show the first processing error - processing stops and the error message is stored in the Lifecycle Entry Detail; Errors are not processed - processing continues and completes as many records as possible, with error messages stored in the Lifecycle Entry Detail.

Status*

Select the status of the transition action. Enable - action is active and executes; Disable - action is inactive and does not execute.

Product*

Some Lifecycle actions are relevant only when a certain product is active. Use this field to define that product.

Note

Upon initial installation, these fields are not visible. Add them to the page through the Personalize option.

Default action handlers

The following action handlers are available for all products:

Name

Description

PrintReport

Prints a report for a record. Specify the report number in the argument.

SendDocForApproval

Sends the current record to the workflow specified for the same table.

CancelWorkflowApproval

Cancels the workflow running for the table specified in the Lifecycle.