Transition Issues
With HAPI, we've made it easy for you to transition issues and even update fields while you transition issues.
Transitioning issues
To transition an issue, run the following script from the script console:
In this example we're starting progress on an issue.
def issue = Issues.getByKey('ABC-1')
issue.transition('Start Progress')
Updating fields while transitioning issues
You can also update fields during a transition. For example:
In this example we're resolving an issue, setting the resolution, and adding a comment.
def issue = Issues.getByKey('ABC-1')
issue.transition('Resolve Issue') {
setResolution('Done')
setComment('resolving this issue')
}
See our Javadocs for a full list of fields.