Solved: Jira Automation - Logged Time from Tasks automatically in Parent Epic too

Samuel Kolloch March 28, 2024

Hey Community, 

I want to create an automation which lets me track my time on Tasks that have a parent epic linked and automatically add the tracked time into the work log of the parent epic. 

I also have an Automation to sum up the Original Estimates to the Parent but somehow it just doesn't want to work for the Time Tracking.

This is my actual Automation: 



Bildschirmfoto 2024-03-28 um 14.39.03.pngBildschirmfoto 2024-03-28 um 14.38.53.pngBildschirmfoto 2024-03-28 um 14.38.36.pngBildschirmfoto 2024-03-28 um 14.38.30.png

3 answers

1 accepted

1 vote
Answer accepted
Stephen Wright _Elabor8_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
March 29, 2024

Hi @Samuel Kolloch 

The Lookup Issues parameter shouldn't be necessary - you're not looking for the total SUM of the time spent, just to add the last logged time to the Epic (if I've understood correctly).

The rule should look like this...

  • Trigger: Work logged
  • Condition: Issue fields condition
    • Field = Issue Type
    • Condition = is one of
    • Value = Task, External Task
  • Condition: Related issues condition
    • Related issues = Parent
    • Condition = Exists
  • Branch: Related Issues
    • Type = Parent
      • Branch-Action: Log work
        • Time spent = {{worklog.timeSpent}}
        • Date started = {{worklog.started}}

Let us know if this works!

Ste

Samuel Kolloch April 1, 2024

Hey @Stephen Wright _Elabor8_

thanks for the suggestion! Unfortunately it didn't work but you definitely understood what I am trying to do. I want to add the logged work on a Task automatically to the work log of the parent epic.

The only problem which still occurs is that it doesn't add the logged time to the parent epic worklog. 

Best, 
Samuel

Samuel Kolloch April 1, 2024

It throws the following error in the audit log:

(I think it has to do with the epic because MT-37 is a Task)
Bildschirmfoto 2024-04-02 um 08.18.52.png

Stephen Wright _Elabor8_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 1, 2024

Hi @Samuel Kolloch 

Can you provide a view of how you setup the whole rule?

I did try this before providing the answer, and it worked! So there might be an error in the setup we just need to identify and fix :)

Ste

Samuel Kolloch April 1, 2024

Hi @Stephen Wright _Elabor8_ 

It finally did work with the following setup which basically is yours :)
Bildschirmfoto 2024-04-02 um 08.29.31.png

Stephen Wright _Elabor8_
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
April 1, 2024

Hi @Samuel Kolloch 

Epic, glad it's working!

Ste

0 votes
Bill Sheboy
Rising Star
Rising Star
Rising Stars are recognized for providing high-quality answers to other users. Rising Stars receive a certificate of achievement and are on the path to becoming Community Leaders.
March 28, 2024

Hi @Samuel Kolloch 

First thing, would you please clarify what you are trying to do?

As written, your rule would log the complete total for all child issues of the epic, every time work is logged.  That may not be what you wanted.

 

Instead, the Work Logged trigger could be used to only add the new information to the parent: https://support.atlassian.com/cloud-automation/docs/jira-automation-triggers/#Work-logged

With the trigger of Work Logged, you may use the {{worklog}} smart value and the attribute of {{worklog.timeSpentSeconds}}s for the logging.  Please note I added a unit of seconds after the value.

Kind regards,
Bill

0 votes
YY哥
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
March 28, 2024

Hi @Samuel Kolloch 

Welcome to our community.

Please try: {{lookupIssues.timeSpent.sum}} .

Thanks

YY哥

Samuel Kolloch March 28, 2024

Thank you @YY哥 !
Unfortunately it still doesn't work.

 

YY哥
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
March 28, 2024

Change lookup JQL to:

"Epic Link" = {{issue.key}}

And show me the audit log after your execution.

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS
AUG Leaders

Atlassian Community Events