Showing results for 
Search instead for 
Did you mean: 
Sign up Log in
Deleted user
0 / 0 points
badges earned

Your Points Tracker
  • Global
  • Feed

Badge for your thoughts?

You're enrolled in our new beta rewards program. Join our group to get the inside scoop and share your feedback.

Join group
Give the gift of kudos
You have 0 kudos available to give
Who do you want to recognize?
Why do you want to recognize them?
Great job appreciating your peers!
Check back soon to give more kudos.

Past Kudos Given
No kudos given
You haven't given any kudos yet. Share the love above and you'll see it here.

It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

[GROOVY] Sprint information


I am trying to get Forecast and completed via Groovy, i managed to get issues per sprint but i don't know how to check if issue were added during a sprint which is crucial to get forecast

for now my code looks like that

import com.atlassian.greenhopper.service.sprint.SprintManager
import com.onresolve.scriptrunner.runner.customisers.JiraAgileBean
import com.onresolve.scriptrunner.runner.customisers.WithPlugin
import com.atlassian.greenhopper.service.sprint.SprintIssueService
import com.atlassian.jira.component.ComponentAccessor
import com.atlassian.greenhopper.service.sprint.Sprint
import com.atlassian.greenhopper.web.rapid.sprint.CompleteSprintStats
import com.atlassian.greenhopper.web.rapid.issue.statistics.IssueSprintStatistics
import com.atlassian.greenhopper.web.rapid.issue.statistics.IssueSprintStatistics.Builder


SprintManager sprintManager

SprintIssueService sService


def tmp = ""
int forecast = 0
int completed = 0
sService.getSprintsForIssue(ComponentAccessor.userManager.getUserByName("igot"), ComponentAccessor.issueManager.getIssueObject("ASUM-698")).getValue().each{sprint->
sService.getIssuesForSprint(ComponentAccessor.userManager.getUserByName("igot"), sprint).getValue().each{issue->


I have found this class but i don;t know how to use it :/, or maybe you know some other solutions to reach this data?
Can somebody help me with that?

thanks in advance
Maciej O. 

0 answers

Suggest an answer

Log in or Sign up to answer
Community showcase

The benefits of using Jira in different departments

Jira is a great tool to use across different departments. Forget that paperwork – switch to Jira and get that tasks done smoothly. Marketing Jira allows for a complete digital transformation of you...

84 views 0 5
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you