Forums

Articles
Create
cancel
Showing results for 
Search instead for 
Did you mean: 

Automation: copying Initiative name to custom field for use in Tempo Logged-Time exports

Danny Zaat March 14, 2023

Hi all,

I'm fairly new to Jira and need some advice around how to set up an automation.

Context:
We are running Jira Premium and have created the Initiative issue as the level above Epic.

Our hierarchy looks like this:

Project (= corporate division)
Initiative (= project name)
Epic (= workstream)
Tasks/Stories (= work)
Subtasks (= smaller bits of work).

My team log time in Tempo by logging time against the tasks & sub-tasks they are working on. On a monthly basis I have to run a Logged-Time report for our Finance team (this consist of a raw data export from Tempo to an Excel spreadsheet). 

Problem:
Tempo will only pull through details of system issues and custom fields in Jira - the hierarchy stops at the Epic level as Inititive is not a Jira system issue. This means that I lose sight of which Inititive the logged work belongs to.

Proposed solution:
I have created a custom field called "Initiative ID" which is present on the Initiative, Epic and Task/Sub-task screens. I would like to use an automation sequence to automatically populate the "Initiative ID" custom field in all issues with the name of the Initiative (taken from the Initiative "Summary" field). I am then hopeful that the Initiative ID field is pulled through by Tempo when creating the logged-time report.

Alternative solution:
When the Epic is created, the user will need to populate the "Parent" link field to link the Epic to the Initiative. Would it make more sense to use the "Parent Link" field as a trigger for this automation rather than the creation of the Epic as you need to tell the Epic who its parent is before you can use that information to populate another custom field?

Ask:
Can someone show me how to set this up as an automation please? Please note that we are not in a position to purchase ScriptRunner (this has been suggested previously) so I am reliant on running automations.

Many thanks for your help.

Best,

Danny

2 answers

1 accepted

1 vote
Answer accepted
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 16, 2023

Hi @Danny Zaat 

Now that you have your field copied from the Initiative to the Epic, you may need one or two more rules to cascade down the information, using a divide-and-conquer approach:

  • one rule approach
    • triggered on an update to your field
    • add if/else conditions, one for each issue type level (e.g. epic versus story)
    • inside the condition, add a branch on the respective child issues
    • and edit the branched-to issue to copy the field from the trigger issue
  • two rule approach
    • same as above, except each rule has a different condition/branch based on the trigger issue...
      • for example, when triggered on an epic, branch to the child issues, or
      • when triggered on a story, branch to the subtasks

Both of these rules would need the "Allow Rule trigger" option enabled, as your initial rule will make the triggering event (i.e., copying the field from the Initiative to one-to-many Epics)

The two-rule approach may be safer to test/debug and to prevent potential run-away rule execution if there are errors.

Kind regards,
Bill

0 votes
Danny Zaat March 16, 2023

Update:

I've successfully managed to write the automation to copy the Initiative Summary field over to the Epic Custom Field. However, getting that data into linked Tasks and Sub-tasks still eludes me. The quest continues ...

Suggest an answer

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

Atlassian Community Events