Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.


Panel

On this page

Table of Contents
maxLevel2
exclude(On this page|Use case).*
stylecircle
typeflat
separatorpipe



UI Text Box
sizemedium
typeinfo

Use case

Often it is necessary to keep parent issues and sub-tasks in sync. To do so, the following automation rules rule comes with a handy configuration that automatically updates specific sub-tasks' field values with their corresponding values of their parent issue's value.

In our use case we want to automatically update the priority field.

Page properties
hiddentrue
Function

<link to function being used>

Use case descriptionWhen the priority is changed, all sub-tasks will be updated accordingly.
Complexity

Status
colourGreen
titleBeginner




UI Steps

Image AddedField changed event

UI Step

Excerpt Include
DECADIS:Automation Use Case - Create Rule Step
DECADIS:Automation Use Case - Create Rule Step
nopaneltrue


UI Step

Add a Trigger → Field Changed Event

UI Steps


UI Step

Field

Choose Priority


UI Step

Changed to

Choose Any value



Image AddedIssue selector

UI Steps

Image Removed Field Changed Event

UI Step

Create a new rule and name it appropriately.

UI Text Box
typetip

Providing a description will help you to identify what the rule does but this step is optional.

UI Step

Add a trigger and choose the Field Changed Event, set the Field* to Priority and select Any value.

Image Removed Issue Selector

UI Step

Add SelectorIssue Selector selector → Sub-tasks

UI Text Box
typeinfo

No further configuration needed.


Image Modified

Update Field

 Update field configration

UI Step


UI Steps


UI Step

Next to Issue selector click on Add → Action → Update Field


UI Step

Field

*

Choose Priority


UI Step

Update to

*

Choose Value returned by parsed expression


UI Step

Parser Expression

*

Code Block
linenumberslanguagetruebash
%{trigger.issue.priority}
# Since we want to get the value from that issue that is triggering the rule, we add the "trigger" prefix.


UI Text Box
typeinfo
Both basic text and advanced  parsing text parsing modes work for this expression.





UI Step
Excerpt Include
DECADIS:Automation Use Case - Enable Rule
DECADIS:Automation Use Case - Enable Rule
nopaneltrue
Activate the rule by clicking on the Activate rule button  Image RemovedImage Removed




Image ModifiedScreencast

This is how the configuration above should look on your screen

Multimedia
namekeep_priority_of_parents_and_sub-tasks_in_sync.mp4
width700


Image AddedImport the example

Import the JSON file below to get started in no time


UI Expand
titleJSON


UI Text Box
typewarning

After importing the JSON file, make sure to check the configuration of the rule. Non-existing configuration elements (issue types, fields, values etc.) will be highlighted.


Code Block
languagejs
themeMidnight
linenumberstrue
{
    "name": "Keep priority of parents and sub-tasks in sync",
    "description": "",
    "creator": "admin",
    "status": false,
    "triggerData": "",
    "triggerType": "FIELD_CHANGED_EVENT",
    "configuration": {
        "refs": [
            "issue",
            "system",
            "trigger.issue",
            "trigger.parent"
        ],
        "fieldId": "00017",
        "option": "any",
        "triggerType": ""
    },
    "children": [
        {
            "sequence": 0,
            "type": "ISSUE_SELECTOR",
            "ruleEntityType": "SELECTOR",
            "configuration": {
                "refs": [
                    "issue",
                    "project",
                    "system",
                    "trigger",
                    "trigger.issue",
                    "trigger.parent"
                ],
                "option": "subtasks",
                "issueListExpressionParsingMode": "issues",
                "actingUser": "field_00020"
            },
            "children": [
                {
                    "sequence": 0,
                    "type": "UPDATE_FIELD",
                    "ruleEntityType": "ACTION",
                    "configuration": {
                        "refs": [
                            "issue",
                            "issues",
                            "project",
                            "selector.issue",
                            "selector.parent",
                            "system",
                            "trigger",
                            "trigger.issue",
                            "trigger.parent"
                        ],
                        "fieldId": "00017",
                        "mode": "parser",
                        "value": "%{trigger.issue.priority}",
                        "valueParsingMode": "textAdvanced",
                        "sendMail": "true",
                        "actingUser": "field_00020"
                    },
                    "children": null,
                    "hasChildren": false
                }
            ],
            "hasChildren": true
        }
    ],
    "hasChildren": true
}




Image ModifiedRelated examples

Page properties report
headingsAutomated action, JWT feature, Label
cqllabel = "use-case-auto" and label = "update-field" and space = "JWTSDC"
If you still have questions regarding this example or others, feel free to refer to our support team.


Excerpt Include
DECADIS:Contact support
DECADIS:Contact support
nopaneltrue


Page properties
hiddentrue


JWT feature

Image Added

Automated actionUpdate field action
Label




Page properties
hiddentrue



Status
Tech review

Status
colourGreen
titledone

Style guide

Status
colourGreen
titledone

Status
titleto do
Status
colourGreen
titledone
Status
colourYellow
titleneeds review
Status
colourRed
titleflagged