Just a heads up: On March 24, 2025, starting at 4:30pm CDT / 19:30 UTC, the site will be undergoing scheduled maintenance for a few hours. During this time, the site might be unavailable for a short while. Thanks for your patience.

×
Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Comment Level validator

Tomasz Bryla
Contributor
February 21, 2019

Hi,

I would like that if the user sets the Coment Level to a different one than All Users, it will not be possible to perform the transition to the next status. A comment is obviously required.

I tried to solve this problem like this:

Issue issue = issue
def cfm = ComponentAccessor.getCustomFieldManager()

def comment = transientVars.get("comment")
if (comment.getRoleLevel()) {

throw new InvalidInputException("Comment must be public")

}

0 answers

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events