Use same inheritance logic for custom period field as for estimation field

Hi,

 

is there any way to apply the same logic as for the estimation or tracked time field for a custom field of the period type?

 

Our use case is that we have field for the remaining estimate which shoul aggregate at parent issues the same way the estimation or time tracked does.

 

Thanks in advance.

8 comments
Comment actions Permalink
Official comment

Hi,

I believe you can try to implement this behavior using workflows (https://www.jetbrains.com/help/youtrack/standalone/Quick-Start-Guide-Workflows-JS.html). An on-change rule which triggers on updating child's period field or on adding a parent link should work. 

Please refer to https://www.jetbrains.com/help/youtrack/standalone/Default-Workflows.html for more examples. 
Hope it helps.

Comment actions Permalink

Yes, this behavior could sure be implemented by a workflow.

However the behavior is rather komplex, since periods need to be inherited bottom to top and not top to bottom like most other fields.

A top to bottom inheritance is rather easy and is implemented in several workflows in our site.

The bottom top inheritance like it is used for the estimation and time tracked field is rather complex, since there might be several child issues which estimation need to be summed up at the parent.

Since this is rather complex to implement and is already done for the estimation and time tracked field we hoped there is an already existing workflow to use or at least a function to call in a custom workflow to do that.

So far I have not found a workflow or function to do that.

 

The reason we need this is that YouTrack has no "remaining estimation" field, meaning a period field that tracks the difference between estimation and time already tracked. We need that in most projects in our agile board to better track the remaining workload within a sprint.

We have already implemented the logic to compute this value however still have not found a way to aggregate the value bottom up like the estimation or time tracked. This is needed so, for example, epics do reflect the remaining estimate of all its children.

0
Comment actions Permalink

I'm afraid there is no out-of-the-box workflow of function for that.

However, our time report does display remaining time - will it work for you? You can track the progress there.

0
Comment actions Permalink

Thanks for the swift reply.

 

Unfortunately we need this information at each ticket and computed in real time, since this often is an essential information in planing.

0
Comment actions Permalink

I'm afraid workflow is the only way in this case then. Please let us know if you need any assistance with that. 

0
Comment actions Permalink

Thanks for the update.

 

So we will evaluate if we can implement that as a workflow.

However such an aggregation for the time from bottom (individual task) to top (epic) over several layers should not be trivial to implement in JavaScript.

 

Since a parent issue might have several children and we need to always update all the way to the root, we would need to implement  complete graph algorithm.

 

If using the same logic as the fields for time management do to accomplish that is not possible, any examples that accomplish something similar in a workflow would be greatly appreciated.

 

0
Comment actions Permalink

After talking to another one of our software architects we realized that this kind of inheritance can be accomplished rather easily using another guard function and an iterative process.

I will share the resulting workflow as soon as we have completed testing on that workflow.

0
Comment actions Permalink

Good to hear that, thanks a lot!

0

Please sign in to leave a comment.