Post function to assign issue to current sprint

pierson@mi@hrc.nyc.gov January 3, 2020

I am hoping to add a post function for the transition from any status to In Progress that would automatically assign the issue to the current sprint. This would be helpful to ensure that issues are not lost. Occasionally, someone will start working on fixing a bug without telling the rest of the team and will mark it as "in progress." 

If need be, I am willing to update this post function every time we switch between sprints (although I would prefer not to need to do that.) I already tried adding a post function with the sprint name + ID and kept getting an error message when I moved issues from to do to in progress. 

1 answer

0 votes
brbojorque
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 3, 2020

Hi pierson@mi@hrc.nyc.gov ,

Do you have any existing script to start with? I would assume you are using ScriptRunner?

pierson@mi@hrc.nyc.gov January 6, 2020

Hi @brbojorque

I was able to use a post-function to automatically assign someone to the issue without needing to write a script. I thought there might be a simple solution that would let me at least enter the name/id of the sprint and update it every two weeks.

I haven't used ScriptRunner before, so I will need to take some time to learn how to write scripts in Jira that if that is the only option. 

-Miriam

Carolyn Nelson April 6, 2020

Is there any update on this question?  Can issues be auto-assigned to the Current sprint in a post-function in Jira Cloud?  Asking for a friend (user) :-)

Like # people like this
Rasmus Vedel August 13, 2021

I have the same need. Would expect to find a postfunction, but it doesn't seems as an option. 

Anyone who have this problem solved?

Juha Nevamäki August 13, 2021

At least in Jira Server, you can use ScriptRunner post-function to add Task to current sprint.

https://docs.adaptavist.com/sr4js/latest/features/workflows/post-functions/built-in-post-functions/add-remove-from-to-active-sprint

Jay 제이 Ahn December 29, 2021

You guys can set it by `Automation`. It is really easy.

 

Check it out.

1. Project Settings -> Automation -> Create Rule

2. Select `Issue transitioned` as new Trigger, and Save

3. Select `Open` as From status, and `In Progress` (Probably you need to create multiple automation rule if you want from `any status` to `In Progress`

4. Select `New action` as component, and select `Edit Issue`

5. Select `Sprint` field from dropdown, and select `Active Sprint`, and Save

6. Add name, and Turn On 

Like Fabrizio Dovesi likes this
Rasmus Vedel January 3, 2022

Thanks Jay. This solution works for Cloud, unfortunately not for local hosted installations.

Suggest an answer

Log in or Sign up to answer