Skip to main content

Version: 24.10

Actions

The actions attribute is used to whitelist user actions on the List and Details screens. They appear at the top right of the Details screen, either as a button if there is only one available action, or in a dropdown list if multiple actions are available.

Single actions entry

As of Journey Brokers version 23.10, there is only one set of actions, which is defined as a single actions entry in the config files.

Actions appear in a panel at the top right of the Details screen in Desktop mode, or at the bottom right for Mobile.

Supported actions are, in the order that they are displayed:

  • Receipt
  • Add Notes
  • View Form (Resume)
  • Recover
  • Withdraw

Receipt

The Receipt action opens a modal displaying the current Txn formReceipt. If there is more than one receipt attached to the Txn, the modal includes a dropdown list allowing the user to select a receipt to view.

Display rules

txn.job || txn.receiptUrl;

Add Notes

The Add Notes action displays a modal in which notes for the current task can be viewed and added.

tip

You can reply to an existing note from the Notes card on the Details screen. To reply to a note, click View Thread for the note.

Display rules

This action has no display restrictions.

Recover

The Recover action re-opens an abandoned Txn.

Display rules

txn.taskType !== 'Review' &&
txn.availableActions.includes('reopen') &&
txn.userLoginName === currentUser &&
txn.formStatus === 'Abandoned';

View Form (Resume)

The View Form action opens a modal displaying the form with the current Txn formUrl and &pageId='' appended to it.

info

We send a message using a postMessage API with the following schema:

{
pageId: '';
}

Display rules

txn.taskType !== 'Review' &&
!['Completed', 'Abandoned', 'Expired', 'Submitted'].includes(txn.formStatus);

Withdraw

The Withdraw action is used to abandon a saved Txn.

Display rules

txn.taskType === 'Review' &&
txn.userLoginName === currentUser &&
!['Completed', 'Abandoned', 'Expired', 'Submitted'].includes(txn.formStatus);

Invoke Fluent Function on Single Actions

Some actions have the ability to invoke a fluent function once the action has successfully completed. Those actions are:

  • Recover
  • Withdraw

The invoke functionality can be accessed by adding the onSuccess property to the action and the appropriate invoke properties. See Invoke for more information.

space config
{
...
actions: {
Claim: {
label: 'Claim',
onSuccess: {
serviceName: 'DAO - Rerun Integrations',
versionNumber: '0.1.0',
},
},
Release: {
label: 'Release',
},
}
...
}

Actions config

{
...
actions: {
ViewForm: {
label: 'Resume',
},
Withdraw: {
label: 'Withdraw',
},
Recover: {
label: 'Recover',
},
Receipt: {
label: 'Receipt',
permissions: {
type: 'group',
value: ['Manual Review'],
}
},
},
...
}

Attributes

To review the list of supported attributes, see CurrentSpaceActions and CurrentSpaceJobActions.