Lifecycles
A lifecycle describes the stages a content goes through during its existence: for instance Draft, In review, Approved, Archived: and what is allowed at each of them.
It answers the need to impose a course rather than leaving it to the goodwill of the users. A lifecycle keeps the current state in a metadata, controls the conditions to meet to enter a state, runs actions on entering that state (create a version, notify, sign, propagate), and only opens the planned transitions to the next states. A document therefore cannot be approved if it does not meet the posed conditions, and its approval triggers by itself what must follow.
The lifecycle can be applied on contents or business objects (Case), and a switch in the navigation bar moves from one to the other. Several lifecycles can be created.
To create a lifecycle, first enter a description, then choose in State metadata the metadata that keeps the current state of the content (by default standard.status).
Then define all the stages of the lifecycle in the table. The starting state is mandatory and cannot be deleted, it is used to initialize the lifecycle.
Creating stages
To create a new stage of the lifecycle, click the "+" icon, this inserts a new stage in the table on the left of the screen.
Name: enter the name of the state
Type:
- State: this type changes the state of the state metadata
- Action: this type does not change the state metadata
Create as many stages as needed.
Selecting a state in the first column opens the menu to:
- Change the order (move the value up or down)
- Delete the state
At any time, you can preview the lifecycle by clicking the "preview" button.
Stage configuration
To configure a stage, click it and the state configuration is displayed on the right of the screen.
Three tabs are available: conditions, actions and next states.
Conditions
A stage can carry as many conditions as needed, one per row. All of them must be met to enter the state, after which its actions are run. The conditions are classified by categories: first choose a category, then the condition.
Their name is enough to understand them. Only the settings that are not obvious are detailed below.
Metadata
- Metadata is equal to at least one of the values
- Metadata is not equal to any of the values
- Metadata is empty
- Metadata is not empty
- Has aspect
- Does not have aspect
Content
- Has at least one of the formats: among the formats declared in the content type module.
- Does not have any of the formats
- Has at least an attachment
- Does not have any attachments
- Is in edition
- Is not in edition
- A signature is in progress
- A signature is not in progress
- Can be archived
Package
- Package is valid: in the sense of the package validation modules.
- All components are in status
Relation
- All related contents are in status: specify the relation, its direction and the expected state of the related contents.
- Has related content / Has no related content: specify the relation and its direction.
User
- User is a member of at least one of the groups
- User is not a member of any of the groups
- User has at least one of the roles
- User does not have any of the roles
- Metadata is equal to at least one of the values / Metadata is not equal to any of the values: cover a metadata of the signed-in user, not of the content.
Advanced
- GQL Predicate: GQL condition evaluated on the current content. For instance:
standard.status = 'Draft' or standard.status = 'Approved'(see the GQL reference guide). - JavaScript: condition evaluated on the metadata of the current object, exposed through
metadata.<metadata>. For instance:metadata.standard.status == 'Draft' && metadata.core.object_type == 'test'.
All conditions
Invalid condition message: message displayed if the condition is not met, in the current language ("card" icon to enter every language).
Selecting a condition in the first column opens the menu to:
- Change the order (move the value up or down)
- Delete the condition
Actions
A stage can carry as many actions as needed, run in order on entering the state. As for the conditions, only the settings that are not obvious are detailed below. The actions are grouped as in the list of the interface.
Metadata and aspects
- Set metadata value: accepts contextual values, for instance
${standard.subject}. - Set metadata multiple values: mode Insert (at the start), Append (at the end) or Replace all.
- Change state value: updates the metadata defined in State metadata with the name of the state. When this action is applied can be defined. By default, it is run last.
- Apply a metadata composer: recomputes a metadata from the others.
- Apply the propagation: propagates metadata to the related contents.
- Remove the aspect
Versions
- Version: creates a version, major or minor.
- Delete previous versions: a GQL predicate restricts the deleted versions. Empty, every one is deleted. For instance:
standard.status = 'Draft' or standard.status = 'Approved'. - Delete all versions
Sealing and retention
- Seal content: putting a seal guarantees that, as long as the seal is valid, neither the metadata nor the formats of the document (primary, PDF, thumbnail) have been altered. This action must be run at the end of the actions list.
- Apply retention: moves the document to retention by applying the configured retention module. Once in retention, a document cannot be changed or deleted. This action must be run at the end of the actions list.
Formats
- Request a format conversion: generates a PDF format of the content.
- Save metadata transfer to primary format: writes the metadata of Any into the primary file, so it travels with it outside Any.
- Delete secondary format: a specific derived format or every secondary format. Keeps the primary.
Tasks, notifications and integrations
- Send a workflow task
- Send a notification
- Send to Synchronization queue
- Request an external manual signature
- Execute the REST calls of the extension
Actions on other contents
- Apply action for other versions: posts an event, or changes the state, on the other versions. The event must exist as a "triggering event" of a next state.
- Apply action on related contents: same principle, on the contents reached through a relation (name and direction). Specify the targeted lifecycle.
- Apply action on package components: posts an event on the components.
- Apply action on other contents: on the set defined by a GQL predicate. For instance:
standard.status = 'Draft' or standard.status = 'Approved'.
Subscription
- Automatic subscription: subscribes groups, users, the current user, or those listed in a metadata.
Archiving
- Archive the content: sends the content to an archiving system. Must be run last.
Transitions (next states)
From a lifecycle state, the possible next states can be defined. As many as needed can be defined, one per row in the table.
Moving a document to the next state can be done manually from the lifecycle button of the selection panel, or automatically through the triggering events. They change the state of a document automatically either after a particular action (a new version, for instance), or after the acceptance or the rejection of a workflow task.
- Next state: name of the next state.
- Hidden in menu: hides this transition in the lifecycle menu. No menu is then displayed to the user to move to that next state (for instance if the transition is done by a workflow task).
- Label: label displayed in the interface menu to move to that next state, in the current language (click the "card" icon to enter every language). It is also used in the workflow task to replace the configured label of the task button. Two transitions (accept/reject) to two different states can be configured with two different labels, which adds two buttons in the task acceptance dialog box instead of the one configured in the task: just add two transition rows in the table, one for
state1and one forstate2. - Triggering event: name of the event that triggers this next state.
-
Workflow task:
- Action: determines which action on the workflow tasks triggers the transition: Accept, Reject or Abort, which happens when the task administrator aborts the workflow.
- Workflow task: name of the workflow task. Several can be selected, so as to trigger a transition only if several workflow tasks have been accepted, for instance. The transition is triggered when every task is finished. The acceptance event is triggered according to the acceptance settings of the task, whereas the rejection or the abort is triggered as soon as one of the selected tasks is rejected or aborted.
-
Built-in: event emitted automatically by the system that triggers the transition. The available events are grouped below:
- Version
- New version created: a new version has been created, whatever its type.
- New major version created: creation of a major version (for instance
1.3→2.0). - New minor version created: creation of a minor version (for instance
1.1→1.2). - Latest version overwritten: the content of the latest version has been replaced without creating a new version number.
- Package
- Package validated: the package now satisfies the validation modules.
- Package invalidated: the package no longer satisfies the validation modules.
- Signature
- Content signature started: the signature flow has just started.
- Content is signed: the signature finished successfully.
- Content signature rejected: a signatory rejected the signature.
- Content signature is aborted: the signature was cancelled or interrupted.
- Content is archived: the content has been sent to archiving.
- Version
-
Free input: name of an event entered in a task configuration.
-
- Confirmation required: checks whether a confirmation is needed to move to that next state.
- Confirmation: confirmation message to enter that next state, in the current language (click the "card" icon to enter every language).
- Signature required: tick this box if an electronic signature is required. The content signature flow is used to resolve the signature module to use.
- Signature: informative column corresponding to the old signature form, now migrated to a signature module. Create a content signature flow to resolve the signature. The column disappears once that flow is created.
- Content metadata form: fills in the metadata. Enter the name of the configured metadata dialog box (in the dialog boxes module) for the metadata edition.
For the electronic signature, you must create a dialog box to sign with the dialog box module. This dialog box must hold at least two fields:
- key.login: to enter the login name
- key.password: to enter the password
It can also hold other keys that could be displayed on the signature page of the content transformation module, such as the signature intent.
In the content transformation module, a signature page can be defined with the keys defined in the dialog box. login is displayed as "Signatory" and shows the name of the user instead of the login.
Flows
This module can be used in the following flows: