WF condition on custom field with ScriptRunner

BEN FRIEDMAN February 7, 2021

Hi,

inside a WF, i choose a transition, choose conditions, choose scriptrunner.

Now, i can enter a condition that will be relevant for the condition.

I dont know how to write the condition i want in the correct syntax.

there is a customfield of type checkbox named Testing (the choice is Yes).

the condition should be if Testing IS NOT yes, then the transition should appear.

1 answer

Suggest an answer

Log in or Sign up to answer
0 votes
Kristian Walker _Adaptavist_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
February 7, 2021

Hi Ben,

Thank you for your question.

I can confirm that Workflow Conditions inside of ScriptRunner for Jira Cloud are defined using the Jira Expression Framework as documented in the Atlassian API documentation page located here or in the documentation page located here which explains how to add in a new condition to your workflow.

I can confirm that when viewing the Jira Expression Framework API documentation page linked above you can navigate to the Context variables section which shows what variables are provided by this framework that can be used to create the expression.

If you then click on one of the variables it will show all the properties that can be called on the variable for the expression such as for the issue variable as shown here and you will be able to check this to see if Atlassian provides a variable that can be checked against to help create the validator which you require.

I hope this information helps.

Regards,

Kristian

TAGS
AUG Leaders

Atlassian Community Events