groovy script help

Debraj neogi November 30, 2015

in a post-function, what's the syntax for a Condition (groovy expression) that basically says "Dev Assignee field is empty” (and must to be true for the post-function to apply)?

2 answers

0 votes
Phill Fox
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
November 30, 2015

You can use the following formula to check if an assignee field is empty and combine with other actions.

if (! cfValues['Assignee']) ...

 

Jamie Echlin _ScriptRunner - The Adaptavist Group_
Marketplace Partner
Marketplace Partners provide apps and integrations available on the Atlassian Marketplace that extend the power of Atlassian products.
December 1, 2015

So for a condition on a post-function, for a custom field called Dev Assignee, it would be: cfValues['Dev Assignee'] that should be all that's required

0 votes
Jamie Echlin _ScriptRunner - The Adaptavist Group_
Marketplace Partner
Marketplace Partners provide apps and integrations available on the Atlassian Marketplace that extend the power of Atlassian products.
November 30, 2015

Can you add the plugin tag otherwise people won't see this...

Suggest an answer

Log in or Sign up to answer