How to write if condition in expression?
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-16-2017 01:02 PM
Hi Everyone,
How can i write an if condition using expressions? I actually want to show some variable values in the documentation of the user task if a boolean is true.
Please advice.
Thank you
Labels:
- Labels:
-
Alfresco Process Services
2 REPLIES 2
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-16-2017 02:28 PM
Options
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
03-17-2017 05:22 PM
The standard expression language used in Activiti is JUEL (Unified Expression Language - The Java EE 5 Tutorial ).
As far as I know, JUEL supports ternary (conditional) operators.
e.g. ${failed ? 1 : 2}
If process variable failed == true the expressions returns 1, otherwise 2.
Cheers,
Greg
