t_UIActionsType_UIAction
UIAction : Layout
A UI Action is a user interface handler that is invoked in response to a UIEvent.
Description
UIEvents are raised by views such as MenuItems, Buttons or Pickers. UI Actions can be configured on Portlets, Dialogs, and Layouts.
A UIAction launches (and contains) one of the following when triggered by an event:
* Popup Action - pops up a screen.
* Navigate Action - navigates to another screen or form in the application.
* Script Action - runs custom script.
Properties
condition : codeA script expression that must evaluate to true for the action to fire.
The expression is evaluated after other checks of the action have passed e.g. name/source... If the expression returns true, the action's script is executed. The condition uses the same variables and context available in thier script element, which are different for UIActions, DataActions, and Exception Actions. DataActions have bind, locator, bind, old, this (MDAController), and type. UIActions have event, name parameter, source, and this (MDAController). For documentation on these variables, such as locator, see the script element's documentation.- Example
(instance? (getCurrentAct) 'ActivityPlan)
(null? parameter)
(= locator 'selection)
(not (null? (@ view collectionModel selection)))
Valid values based on“string”. event : identifierThe name of the UIEvent which causes the action to be executed.
- Example
"sysChange" or "sysNavigate", or any custom UIEvent defined in the UIEvent's area of NexJ Studio.
Valid values based on“string”. :?[\p{L}_][\p{L}\p{N}_]*(:[\p{L}_][\p{L}\p{N}_]*)* Value must begin with a letter or an underscore. Case and length are not restricted. Letters, numbers and underscores are allowed. Colon is used as a scope separator. Spaces and other punctuation characters are not allowed.
language : schemeLanguageTypeValid values based on“languageType”. scheme scheme scripting language
source : stringA View name pattern used to invoke the action in response to a specific UIEvent raised by a specific view, or views.
The action will only handle events of the correct type from appropriate sources. A blank source defaults to "*" which means "handle the specific event raise from all views".
The source value is a list consisting of the folling parts: (ScreenRefSpec FormRefSpec ControlSpec) where ScreenRefSpec is ScreenRefName symbol, or "*" symbol, or list of ScreenRefName symbols. FormRefSpec is FormRefName symbol, or "*" symbol, or list of FormRefName symbols. ControlSpec is ControlName symbol, or "*" symbol, or list of ControlName symbols.
If a part is skipped it is considered to be the "*" symbol.
The format of the source varies depending on which level the action is configured: Application: (ScreenRefSpec FormRefSpec ControlSpec) Sreen: (FormRefSpec ControlSpec) Form: (ControlSpec)- Example
For Application:
1. Person EntityList
Consideres the event coming from all the controls on the EntityList formRef of the Person screenRef.
2. Person * personName
Considers the event coming form the control named "personName" from all the formRefs of the Person screenRef.- Example
For Screen:
1. EntityDetail lastName
Considers the event coming from the control named "lastName" from the EntityDetail formRef.
2. EntityDetail (lastName firstName)
Considers the event coming from the control named "lastName", or control named "firstName" from the EntityDetail formRef.
Content
Choice of:
t_UIActionType_Script [1..1] - Script for a UIAction
t_UIActionType_Popup [1..1]
t_UIActionType_Navigate [1..1]
Parents
Application_UIActions - The set of ui actions defined for the application.
Screen_UIActions - The set of ui actions defined for the screen.
Form_UIActions - The set of ui actions defined for the form.
t_Controllable_UIActions - Layout-level UI actions
t_Screen_UIActions - Portlet-level UI actions
t_UIActionType_Script
Script for a UIAction
Parent topic: Application_UIActions
Parent topic: t_Controllable_UIActions
Parent topic: t_Screen_UIActions
Parent topic: Form_UIActions
Parent topic: Screen_UIActions
Parent topic: reuseable-references