Using Structure fields in a Custom Calculated Field in Jira

201 views
Skip to first unread message

Bryant Mueller

unread,
Nov 9, 2012, 11:12:28 AM11/9/12
to structure-pl...@googlegroups.com
I'm using a Jira Misc Custom Field to calculate actual time spent vs. original estimated time.  https://studio.plugins.atlassian.com/browse/JMCF-53
I want to use the summary fields provided in Structure:
 Sigma Actual Time Spent / Sigma Original Estimate

I'm told that the Structure value for Sigma Actual Time Spent is not the same as the Jira Constant Field Value "aggregatetimespent"  http://docs.atlassian.com/jira/4.0/constant-values.html#com.atlassian.jira.jelly.tag.issue.AbstractCreateIssue.KEY_FIX_VERSIONS

Is this true?
Can anyone tell me what the field value is for Sigma Actual Time Spent and Sigma Original Estimate so I can use them in a calculated field?

Thanks,
Bryant


Igor Sereda

unread,
Nov 9, 2012, 10:55:23 PM11/9/12
to structure-pl...@googlegroups.com
Hi Bryant,

Yes, the totals you see in Structure do not come from any custom field, but are calculated by Structure. They cannot be stored in a custom field in general case because you may have multiple structures and different values for the same issue but in different structures.

To use this value in a calculated field, you need to access Structure API. Some introduction is given here: https://wiki.almworks.com/x/oYF7 and the method you need is ProgressCalculator.getProgressInfo() - see http://almworks.com/structure/javadoc/latest/com/almworks/jira/structure/api/progress/ProgressCalculator.html

Hope this helps!
Igor
Reply all
Reply to author
Forward
0 new messages