How to use JMCF (Jira Misc Custom Fields) to access EpicSumUp Data
Epic Sum Up provides its user with a Java API. You can use this API to extract data from Epic Sum Up to use with other business components however needed.
This enables vast varieties of customization.
To access this data you can use a script extension like Jira Misc Custom Fields (JMCF) within your Jira instance.
General
To access our Java API in JMCF, you may follow the JMCF Documentation.
The available components can be found in our API Documentation.
Basic Examples
JMCF custom field: Calculate time spent for an issue and all of its children
ProgressTimeResult is used to access values that are specifically used as time values.
import com.atlassian.jira.component.ComponentAccessor
import com.atlassian.jira.user.ApplicationUser;
import aptis.plugins.epicSumUp.api.ProgressProvider
import aptis.plugins.epicSumUp.api.model.ProgressTimeResult
ProgressProvider progressProvider = getComponent(ProgressProvider.class)
ApplicationUser currentUser = ComponentAccessor.getJiraAuthenticationContext().getLoggedInUser()
ProgressTimeResult progress = progressProvider.getTimeProgress(
issue,
currentUser
)
return (long) progress.getTimeSpent()