Record Action Component

Record Actions

Function: a!recordActionField()

Displays a list of record actions with a consistent style. A record action is an end-user action configured within a record type object, such as a related action or record list action.

See also: Record Action Item

Parameters

Name Keyword Types Description

Actions

actions

Any Type

List of record action items to display in the field, configured using a!recordActionItem().

Display Style

style

Text

Determines how the list of actions should be displayed on the interface. Valid values: "TOOLBAR" (default), "LINKS", "CARDS", "SIDEBAR", "CALL_TO_ACTION". See the documentation for guidance on how to use different styles effectively.

Display

display

Text

Determines how the given action labels will be displayed in each item. Valid values: "LABEL_AND_ICON" (default), "LABEL", "ICON".

Action Behavior

openActionsIn

Text

Determines how actions should open to the user. Valid values: "DIALOG" (default), "NEW_TAB", "SAME_TAB"

Alignment

align

Text

Determines alignment of the action(s). Valid values: "START", "CENTER", "END".

Accessibility Text

accessibilityText

Text

Additional text to be announced by screen readers. Used only for accessibility; produces no visible change.

Visibility

showWhen

Boolean

Determines whether the component is displayed on the interface. When set to false, the component is hidden and is not evaluated. Default: true.

Notes

  • Actions from different record types may be used
  • When using a Dialog Box for openActionsIn, form submission will complete the chain and the current page state is retained
  • Showing and submitting an action with a Dialog Box retains the users current page state
  • Reference local variable refresh behavior to learn how to refresh specific variables after Dialog submission
  • Dialog Boxes do not support Application Portal and non-SAIL forms

Updated Record Type

Record Types created before Appian 20.1 will need to be updated to use this component. A record type can be updated via the record type designer.

Non-updated record types will not autosuggest record actions in the expression editor.

Examples

These examples are designed to illustrate how to use a!recordActionField() in the Expression editor.

NOTE: Record actions are specific to record types within your environment. If you copy and paste these examples into the Expression editor, they will not evaluate in your Test Rules interface. Use them only as a references.

Record Action Field With No Configurations

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
=a!recordActionField(
  actions: {
    a!recordActionItem(
   /* For the "action" parameter below, replace the record-action reference 
    * (recordType!Department.actions.update) with a valid record-action reference in your environment.
    */
     action: recordType!Department.actions.update,
     identifier: ri!departmentId
    ),
    a!recordActionItem(
   /* For the "action" parameter below, replace the record-action reference 
    * (recordType!Customer.actions.flag) with a valid record-action reference in your environment.
    */
     action: recordType!Customer.actions.flag,
     identifier: ri!customerId
    )
  }
)

Displays the following:

Record Action Field with Refresh Variables

1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
=a!localVariables(
  /*
  * The parameter 'refreshAfter' in a!refreshVariable() can be used to refresh data when
  * record action dialogs are submitted. Do this to update data related to the record action.
  */
  local!case: a!refreshVariable(
    value: fn!queryrecord(
    /* Replace the recordType reference below (recordType!Case) with a valid   
     * recordType reference in your environment.
     */
      recordType!Case,
      query: a!query(
        filter: a!queryFilter("id","=",ri!caseId),
        pagingInfo: a!pagingInfo(1,1)
      )
    ).data,
    refreshAfter: "RECORD_ACTION"
  ),
  {
    a!sideBySideLayout(
      items: {
        a!sideBySideItem(
          item: a!richTextDisplayField(
            labelPosition: "COLLAPSED",
            value: {
              a!richTextHeader(
                text: "Case Details"
              )
            }
          )
        ),
        a!sideBySideItem(
          item: a!recordActionField(
            actions: {
              a!recordActionItem(
              /* Replace the record action reference below, recordType!Case.actions.edit, 
               * with a valid record action reference in your environment.
               */
                action: recordType!Case.actions.edit,
                identifier: local!case.id
              )
            },
            openActionsIn: "DIALOG",
            style: "LINKS",
            display: "LABEL_AND_ICON",
            showIcon: true,
            align: "END"
          )
        )
      },
      alignvertical: "MIDDLE"
    ),
    a!columnsLayout(
      columns: {
        a!columnLayout(
          contents: {
            a!textField(
              label: "Priority",
              labelPosition: "JUSTIFIED",
              value: local!case.priority,
              readonly: true
            ),
            a!textField(
              label: "Status",
              labelPosition: "JUSTIFIED",
              value: local!case.status,
              readonly: true
            ),
          }
        ),
        a!columnLayout(
          contents: {
            a!textField(
              label: "Created On",
              labelPosition: "JUSTIFIED",
              value: local!case.createdOn,
              readonly: true
            ),
            a!textField(
              label: "Created By",
              labelPosition: "JUSTIFIED",
              value: local!case.createdBy,
              readonly: true
            )
          }
        )
      }
    )
  }
)

Displays the following:

Open in Github

On This Page

FEEDBACK