Back to last step in workflow

I am trying to come up with a way to reopen a task back to the step it was in before. So I have a designed workflow with approvals and each step has an approved denied step. Denied goes to closed. Is there a way to reopen the ticket and have it go to the previous Step in the approval process only? I do not want to have the reopen be a way to by pass a approval step or force it to go through the whole thing again. I think Groovy is the best way but i lack the skills to write a groovy script.

1 answer

1 accepted

0 vote

You don't need any scripting to do this, unless you want to automate it for some reason.

To "go back" in a workflow, you need to create a transition from the current step to the previous one (or earlier).  If you do need to automate it, you still need that transition for the automation to use it!

I am aware of how to create a step back. That part is easy. I want to prevent it from going from closed to a step that it has not been in there by bypassing the approval process. Here is the proposed workflow. 

IR-4568.JPG

Ah, I see, I'm afraid I didn't get that from the question.

Yes, you can script this - have a field that says "previous status", set it as you go into "closed" and then use conditions to say "can only go back to status named in that field".  Or you can script the condition

But, have a look at the JIRA Misc workflow add-on before you dive into Script Runner - it has "previous status" conditions in it already.  If you already have SR, then use it (it can do everything JMWE can do, and a lot more), but if you don't have other uses for SR, this might be a better option for you.  (Yes, I'm doing my company out of a possible SR sale there, but JMWE may be better in this case, and I don't want to be too biased.  But, SR is great!)

Suggest an answer

Log in or Sign up to answer
How to earn badges on the Atlassian Community

How to earn badges on the Atlassian Community

Badges are a great way to show off community activity, whether you’re a newbie or a Champion.

Learn more
Community showcase
Published Thursday in Confluence

Three common content challenges + how to manage them

An efficient enterprise content management system, or ECM, is a must-have for companies that create work online (cough   cough, all companies). If content calendars, marketing plans, and bu...

107 views 0 6
Read article

Atlassian User Groups

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!

Find my local user group

Unfortunately there are no AUG chapters near you at the moment.

Start an AUG

You're one step closer to meeting fellow Atlassian users at your local meet up. Learn more about AUGs

Groups near you