to get current status of issue
to get available actions for the issue
IssueWorkflowManager issueWorkflowManager = ComponentAccessor
Collection<ActionDescriptor> actions = issueWorkflowManager .getAvailableActions(issue);
Remember - you can NOT just "set a status".
Status is NOT a field, it is an indicator of where the issue is in the workflow. To change status, you MUST move the issue through transitions to the new status.
The only time you can "set" a status without transition is when you are adding issues to Jira.
>But i can change the transition rgt?
To try to clarify: You can NOT "change the transition". A transition moves an issue through the workflow. To change the status of an issue, you MUST use a transtion that goes from your old status to the new status.
> & when transition is done the status gets updated rgt?
Correct, because the whole point of a transition is that it changes the status.
No. You are not grasping this.
To change a status, you must use a transition
You cannot get around this. Groovy can tell Jira to do these transtitions. You can detect and automate them. You can protect them so that only certain users or automation can perform them and no-one else sees them.
But. You must have a transtion from A to C if you want to change status from A to C.
Unless you're happy to go from A to B to C, in which case you need transitions from A to B and from B to C.
It's not "the obvious answer", it is the "only answer". You must have that transition.
Hello! My name is Genevieve Blanch, and I'm the Marketing Manager at RefinedWiki, creators of apps to give teams the tools to customize Atlassian platforms. Currently, 44% of the tech team at Re...
Connect with like-minded Atlassian users at free events near you!Find a group
Connect with like-minded Atlassian users at free events near you!
Unfortunately there are no AUG chapters near you at the moment.Start an AUG