Skip to main content
Skip table of contents

Cancel a workflow by requester

This page will explain how to configure the cancellation of a workflow by the requester and how it can be used in Memority portal.

Use Case

Without any explicit configuration a requester cannot cancel its own tasks from the dashboard. However, we offer the configurator the possibility of modifying this behavior to enable this action.

This page will explain how to configure this specific case and how it can be used in Memority portal.

Configuration

Global cases

For cases where the behavior is the same for all workflow steps, or if the workflow consists of just one step, there is in the workflow configuration screen, the Allow cancellation by requester parameter that allows the configurator to authorize or not the cancellation of the workflow by the requester himself.

Capture d'écran 2024-05-16 102153-20240516-082331.png

Workflow configuration screen - Cancellation by requester

Other cases

In cases where the behavior is not the same for all workflow steps (one step is cancelable and the next is not), it is possible toset the flag using the API_WORKFLOW.

GROOVY
<scriptTask id="initScriptTask" name="Some Script Task">
	<script>
		<![CDATA[            
            API_WORKFLOW.setCancellationByRequesterAllowed(true)
            LOG.info("Can requester cancel its tasks ? " + API_WORKFLOW.isCancellationByRequesterAllowed())
            return ActionOutcome.success()
            ]]>
        </script>
</scriptTask>	

If cancellation by requester is no more suitable later in the process, turn the flag off using the same setter method.

Notifications Events

The following Notifications Events are dedicated to the use case of a workflow cancellation by the requester :

Notification event type

Location

Actors

Payload contains ...

CITADEL_WORKFLOW__FEATURE_EXECUTION

BUM

senders

  • system

recipients

  • previousApprover, requester, beneficiary

See Identity link types

Variables:

  • requester

  • cancellationReason

  • beneficiary

  • featureId

  • workflowId

  • attributes

  • originalAttributes

  • operation

  • operationComment

CITADEL_WORKFLOW__ROLE_ASSIGNMENT_OPERATION_EXECUTION

BUM

senders

  • system

recipients

  • previousApprover, requester, beneficiary

See Identity link types

Variables:

  • requester

  • cancellationReason

  • beneficiary

  • role

  • workflowId

  • roleAssignmentChanges

  • operation

  • currentRoleAssignment

  • operationComment

Identity link types

Possible values for identity link types are : 

  • assignee

  • candidate

Usage

Workflows can be canceled by the requester from the workflow dashboard:

Workflow Dashboard

Steps

Preview

1

As an identity with the right to act on objects, perfom an operation triggering a workflow, for example here as a manager we will update the end contact date of one of the people in our scope.

Capture d'écran 2024-02-01 110942.png

2

Click on the Update button.
As configuring, this operation will trigger a workflow (which has been configured to be cancelable by the requester).

Capture d'écran 2024-02-01 102045.png

After confirmation of the operation, a second pop up is displayed :

Capture d'écran 2024-02-01 102054.png
3

When accessing his workflow dahboard, in the submitted by me part, the user task is displayed. And a button is available to Cancel the workflow.

Capture d'écran 2024-02-01 101246.png

4

If applicable (configuration), enter a comment and Confirm the cancellation.

Capture d'écran 2024-02-01 101953.png

Role

In the case of workflow concerning a role assignment, it can also be cancelled by the requester directly from the beneficiary's role dashboard

Steps

Preview

1

As an identity with the right to act on objects, request a role for another identity (one triggering a workflow which has been configured to be cancelable by the requester).

In this example, we have a request button in the workflow dashboard to allow the request of a role :

Capture d'écran 2024-02-01 120306.png

After clicking on it, we can select a role :

Capture d'écran 2024-02-01 120322.png

2

Once, the role request has been made, access the role dasbhoard (of the beneficiary) and click on the action button for the concerned role.

Capture d'écran 2024-02-01 120353.png

3

In the pop-up, click on the Cancel Workflow button.

Capture d'écran 2024-02-01 120403.png

Read Next

  • Actors

    This page details the different types of actors that can be involved in a workflow.

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.