Warning |
---|
Looking for the documentation on the newest versions of SIL Engine and the Simple Issue Language for Jira 8 for Server/Data Center? Click here ! |
Info | ||
---|---|---|
| ||
This routine is available since katl-commons starting with SIL Engine™ 1.0. |
Syntax
...
isNull(variable)
Description
...
Excerpt |
---|
Checks if the provided variable is null or has no value associated and then returns "true. Otherwise ", otherwise returns "false". |
Parameters
...
Parameter name | Required | Description |
---|---|---|
variable | Yes |
Value you want |
to test. |
Value argument can be a string or a variable of any type. |
Return type
...
boolean (true/false)
...
Examples
Example 1 - checking whether the assignee was selected for a ticket
Code Block |
---|
if(isNull(assignee)) { assignee = reporter; } |
Example 2 - checking whether work was logged on ticket
The following line checks whether the Time Spent field contains any work logged on the ticket.
Code Block |
---|
...
isNull(timeSpent) |
You can also use the hasInput routine to check whether certain fields were filled out during a workflow transition. And among those fields you can also check the work logged in particular.
Notes
Note |
---|
If isNull returns "true" the variable has no value attached. isNull will return returns "false" for zero for numeric variables or blank for character/string. |
See also
...
Filter by label (Content by label) | ||||||||
---|---|---|---|---|---|---|---|---|
|