You're on your way to the next level! Join the Kudos program to earn points and save your progress.
Level 1: Seed
25 / 150 points
1 badge earned
Challenges come and go, but your rewards stay with you. Do more to earn more!
What goes around comes around! Share the love by gifting kudos to your peers.
Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!
Join now to unlock these features and more
Welcome to the Atlassian Community!
I'd take a step back from this. Jira already has issue fields that sum up all the parts of the time-tracking field - you don't need to duplicate this!
Thanks very much, Which system field provides the EAC so I can add it to the parent tickets and put it on a two dimensional filter gadget. It's the biggest complaint our Project Managers have.
We then also need a Variance field which calculates the EAC - OriginalEstimate. So that is the next step for scriptRunner and I have never found this field either.
We would like gadgets on dashboards to show this information. Currently we need to export to excel and manually apply the calculations which is manual labor once a week and time consuming.
Thanks for your help!
It's the time-tracking field, which I sometimes call a compound field, because it contains a load of others.
But you won't be able to use it in the two-dimensional filter gadget, they only work with list fields.
You can get them in excel exports though, that could save you a lot of time.
Yes I have used all of these fields. But these fields are not EAC or Variance so the Project Managers have asked for more.
Ideally they want
EAC = Σ Remaining Estimate + Σ Time Spent
Would you know how to create a scripted field with the above total sum? This is ultimately what I was trying to do. Also this?
Variance = Σ Original Estimate - (Σ Remaining Estimate + Σ Time Spent)
To get these important Project Management numbers we have to export into excel and do the caluclations with some manual work.
Thanks very much!
I think you have a bit of a problem here.
The time tracking fields are nothing to do with "Estimate at complete". They are telling you how much time was estimated initially, and how much your people actually did.
"Estimate at complete" should be a measure of what a team said they could do. Something they can then compare against what they delivered.
Your estimate compared with your delivery is a very important metric, and if you are doing it as a time estimate, that's the right way to look at it.
But when you are using an Agile tool, the question is not "EAC = Σ Remaining Estimate + Σ Time Spent", the question is "why did we not deliver what we said we would?".
So, I have a question that is a bit blunt - What is your actual process? Are you trying to do Scrum, Kanban, Lean (and its subsets) or something else? I ask because it feels like you may be trying to wedge the idea of sprints into a linear non-agile process.
Thanks for asking! We do not do Agile. We use V-MODEL following a heavy ISO Software Engineering process and International standards process. We are able to use JIRA for everything we need other then the few measurenements needed by the Project Managers following a PMP training process. Script Runner was recently bought with the expectation that we could script the solution that does not come out of the box.
I would like to find a way to create a scripted field that can add up all the remaining work and work logged and produce a Estmate At Complete. From the PMBOK Guide the sum of the actual cost to date and the estimate to complete.
I wonder if maybe you can anwer the 2nd question about logging? Because I still don't know how to do the logging.
Thank you for taking the time to explain that in detail.
I think I now understand where your need for an EAC comes from, and yes, the sigma-fields don't meet that need (they'll give you the right answer during part of the lifecycle, but not all of it)
I think you're absolutely spot-on to blame the "if" in your code, the line
if(mySubTask.getIssueType() == "Sub-task")
is not going to give you a "true". I'm pretty sure getIssueType() returns an issue type object, not a string, so it will never contain "Sub-task", whatever the name of the sub-task type.
A simple fix would be
if ("Sub-task" == mySubTask.getIssueType().getName() )
but that locks you into having a fixed sub-task name, and your code will fail if someone renames sub-task, and it won't run for other sub-task types.
So, assuming you really do want to include all the sub-tasks of different types, I would use
if (mySubTask.getIssueType().isSubTask() )
For clever logging in scripts, have a skim of https://docs.adaptavist.com/sr4js/latest/best-practices/logging/advanced-logging to see what might work best for you!