Automation For Jira - Writing a rule that updates a parent issue (Initiative) based on an update made to its Child issue (Epic)

お困りですか?

アトラシアン コミュニティをご利用ください。

コミュニティに質問

robotsnoindex

プラットフォームについて: Server および Data Center のみ。この記事は、Server および Data Center プラットフォームのアトラシアン製品にのみ適用されます。

Support for Server* products ended on February 15th 2024. If you are running a Server product, you can visit the Atlassian Server end of support announcement to review your migration options.

*Fisheye および Crucible は除く

 

要約

The purpose of this article is to show how to configure a rule meant to update a parent issue (such as a field update, transition to a new status...) when its child issue is updated, in the case the parent/child relationship is based on the hierarchy level configuration which is a feature from Advanced Roadmap, and which is dictated by the Parent Link field.

It is important to note that the Parent/Child relationship is different from the Parent/Sub-Task relationship which is documented in configuring sub-tasks. The Rule Branches can only be used to search for the Parent of a sub-task, or the  Epic a Story is linked to. However, the Rule Branches don't have an option to search the Parent of an issue when the parent/child relationship is based on Hierarchy Levels.

This is the reason why implementing such use case can be a bit tricky, which is why this KB article was written.

環境

  • Jira Server/Data Center on any version from 8.0.0 (Or Jira Service Management from 4.0.0)
  • Automation for Jira バージョン 7.4.0 以降

ソリューション

For this solution, we will provide an automation rule that will copy the Priority field of a child issue (Epic) into its parent issue (Initiative) when this field is updated.

We will also assume that the parent/child relationship is configured as below:

  • The hierarchy levels are configured so that the Initiative issue type is a parent of the Epic issue type:
  • With such hierarchy level configuration, we will have the Parent/Child relationship described in the examples below:
    • The issue SCRUM-55 is a parent issue of the issue SCRUM-25 (as shown in the Child Issues panel):
    • The issue SCRUM-25 is a child issue of the issue SCRUM-55 (as configured via the Parent Link field):

ルール構成

The automation rule will be configured like this:

  • Add the Field Value Change trigger
    • Fields to monitor for changes: Priority
  • Add an Issue fields condition with the following settings:
    • フィールド: 課題タイプ
    • 条件: イコール
    • : エピック
  • Add a Branch rule component  with the following settings:
    • (warning) Un-tick the option Only include issues that have changed since the last time this rule executed 
    • Type of related issues: JQL
    • JQL: use the JQL query below:

      key in parentIssuesOf("{{triggerIssue.key}}")
  • Inside the Branch rule component, add the Edit Issue action with the following settings:
    • Choose Field to Set...
      • Select "Priority"
      • Select "Copy from trigger issue"


自動化ルールは次のようになります。



最終更新日 2024 年 6 月 27 日

この内容はお役に立ちましたか?

はい
いいえ
この記事についてのフィードバックを送信する
Powered by Confluence and Scroll Viewport.