Value field condition not working for component

Joe Pitt
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
August 24, 2011

I want to show different transitions based on the component. I used the value field compare as string. However, the transition isn't visible. Below is the condition as shown in the workflow. I verifed the spelling and case are the same in the component field and the condition. I only selected one component.

The field Component/s will have to be equal to value Requirement . Compared like String

I also tried the component id compared as a string and number and neither worked. I'm on JIRA 4.1.2.

1 answer

0 votes
JamieA
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
August 24, 2011

I don't know the answer, but in the script runner plugin you could use "Simple Scripted Condition", where the condition would be:

issue.componentObjects*.name.contains("Requirement")

Which would mean one component would need to be Requirement. If you wanted to only allow the transition if that was the only component you could do:

issue.componentObjects*.name = ["Requirement"]


Sonya S_ December 19, 2018

hi, Jamie, 

"issue.componentObjects*.name = ["Requirement"]"

does this code still work in Jira Softwaree 7.2.4 ; Adaptavist ScriptRunner 5.4.7 ?

we tried in workflow condition. however, it doesn't work.

please advise, thank you.

 

Sonya

Like Matthew Gaffney likes this
Matthew Gaffney September 5, 2019

Sonya,

Did you end up figuring this out? I'm trying to do something similar and I'm running into the same issues you had. 

Thank you

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events