Considerations for configuring advanced UI rules
Well-designed UI rules require some planning. This topic provides some guidelines to help you construct useful UI rules that do not have unwanted results.
Considerations for configuring advances UI rules
Pay attention to the following when configuring advanced UI rules:
Consideration | Details |
---|---|
Consider all possible events and negative cases |
|
Consider field security and dependencies |
|
Pay attention to the field validations |
|
Validations supported in Results field
The Results field supports the following validations:
Rule Validation |
setFieldRequired1 |
setFieldEditable2 |
setFieldVisible3 |
setFieldStyle |
selectAll | unselectAll |
---|---|---|---|---|---|---|
Text field |
Yes |
Yes |
Yes |
Yes |
Not supported | Not supported |
Text area |
Yes |
Yes |
Yes |
Yes |
Not supported | Not supported |
Auto-complete list |
Yes |
Yes |
Yes |
Yes |
Not supported | Not supported |
Drop-down list |
Yes |
Yes |
Yes |
Yes |
Not supported | Not supported |
Check box | Yes | Yes | Yes | Not supported | Yes | Yes |
Radio buttons |
Yes |
Yes |
Yes |
Not supported |
Not supported | Not supported |
Date field |
Yes |
Yes |
Yes |
Yes |
Not supported | Not supported |
Web address (URL) |
Yes |
Yes |
Yes |
Yes |
Not supported | Not supported |
Link |
Yes |
Not supported |
Yes |
Not supported |
Not supported | Not supported |
Password |
Yes |
Yes |
Yes |
Not supported |
Not supported | Not supported |
Attachment |
Yes |
Not supported |
Yes |
Not supported |
Not supported | Not supported |
Table component |
Yes |
Not supported |
Not supported |
Not supported |
Not supported | Not supported |
Staffing profile |
Yes |
Not supported |
Yes |
Not supported |
Not supported | Not supported |
1. setFieldRequired UI rule does not work for the above validations when the Display attribute in the field property is set to No or the Visible attribute in Status Dependencies is set to No. 2. setFieldEditable UI rule does not work for the above validations when
3. setFieldVisible UI rule does not work for the above validations when the Display attribute in the field property is set to No or the Visible attribute in Status Dependencies is set to No. |
Considerations for configuring rules in table component
Note the following considerations when you configure SQL rules and/or UI rules for table component:
-
Set Process subsequent rules? option to
Yes
orNo
for different validations. -
Dependencies field is not required for Apply on creation rule event, but required for Apply on field change rule event.
-
Dependencies field supports the following validations:
-
Text field
-
Auto-complete list
-
Drop-down list
-
Date field (short, medium, and long)
-
-
Results field supports the following validations:
-
Text field
-
Text area
-
Auto-complete list
-
Drop-down list
-
Radio buttons (yes/no)
-
Date field (short, medium, and long)
-
Web Address (URL)
-
Link
-
-
UI rules support the following JavaScript functions:
-
setFieldRequired ()
-
setFieldEditable ()
-
setFieldVisible ()
-
showMessage ()
-
setFieldStyle ()
Note: To modify CSS styles, locate and access the
RequestRulesUserCSS.css
file in the following directory:/opt/ppm/[
instance name]/server/[
instance name]/deploy/itg.war/web/knta/crt/css/
.
For more information about these JavaScript functions, see Predefined JavaScript Functions (Advanced Rules Only) or access the Request Rules JavaScript Function Help by clicking the icon next to the Logic field in Rules window of the Validations Workbench.
-
-
You can set table component as a dependency to trigger request type rules.
-
When using SQL rule(s) on text field with Apply on creation rule event, make sure not to use strings "
~^~^~
" and/or "~&~&~
" in any text field as they are reserved. -
When SQL rule(s) with Apply on creation rule event are triggered to override default value of a table component column, the default value may still display for a very short period of time (say 0.5 second) due to server speed.
Limitations
Pay attention to the following limitations when configuring advanced UI rules:
-
Rules can be executed on the printable version of Request Details, but with the following limitations:
-
Only SQL rules and the
setFieldVisible()
UI rule are executed. -
Only the Apply on page load rule event is supported.
-
The printable version should be opened from the request details page instead of by entering the URL address directly.
-
-
If you use special commands, for example,
ksc_store
, in a workflow execution step to change a field value, it does not trigger rules. -
SQL for Hierarchical Display (tree validation) now supports resolving such static tokens as
[SYS.USERNAME]
and[SYS.USER_ID]
. Other types of tokens, such as Request Details or Context related tokens, are not supported. -
If a request contains a rule that uses
KNTA_MULTI.Find_User_full_names([SYS.USER_ID])
fromsys.dual,
you cannot save the request, or remove associated entities from the request. . UseKNTA_MULTI.Find_UserNames([SYS.USER_ID])
fromsys.dual
instead.