It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

"Fix Version" value selection

Hi,

Once the Fix Version field selected with particular value then automatically "Comment" field should be mandatory.

I just wrote the behaviours script but it doesn't work.

log.warn("--- Start behaviour ------------------------------")

def fixVersionsField = getFieldById("fixVersions")
log.warn("Field: " + fixVersionsField)
def fixversion = fixVersionsField.getValue()
log.warn("FixVersions: " + fixversion)
def commentField = getFieldById("comment")
log.warn("comment field: " + commentField)

if (fixversion == "a") {
getFieldById("comment").setRequired(true)
}
else {
getFieldById("comment").setRequired(false)
}

log.warn("--------------------------- End behaviour ---------")

 

===================
Kindly let me know what mistake is that.

1 answer

Could anyone help us on this.

Suggest an answer

Log in or Sign up to answer
TAGS

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you