Clearing FixVersion field in Scriptrunner Behaviours script

Matt Shigekawa August 24, 2020

What's the best way to access the FixVersion field from a Scriptrunner Behaviours server-side script?

We have the below use-case.

IF a custom field called Critical Issue is set to "Approved," THEN:

1) get the fixVersion(s)

2) append fixVersion(s) as labels. example: "Exclude_from_FixVersionA", "Exclude_from_FixVersionB" 

3) clear fixVersion field

1 answer

Suggest an answer

Log in or Sign up to answer
0 votes
Jia Jie
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.
March 3, 2021

Hi Matt,

You could use this to clear the Fix Version field values:

def fixVer = getFieldById("fixVersions")
fixVer.setFormValue([null])
TAGS
AUG Leaders

Atlassian Community Events