Automation for Jira: add comment to linked issue when main issue transitions

Esther Strom
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 14, 2020

I just installed Automation for Jira Lite on our cloud instance, and have found a lot of use for it already. One thing I'm stuck on, though. 

We have two projects: DE and SM. What I need to have happen is:

When an issue in DE transitions (to any status)

Then any linked tickets in the SM project should have a comment added to them.

 

I have a rule set up, but it's not doing anything. Can anyone help me out here? The rule is set up as global, since there's more than one project involved. When I look at the audit log after transitioning a DE issue, it shows that no actions were performed because the linked SM ticket didn't match the condition. Even if I could get it to work, I have a feeling it would still put the comment on the DE ticket, but that would still be a step further than I am now. 

Here's the rule setup/audit log:
ruleSetup.png

Note that the Linked Issue condition looks like it's saying that all link types need to match project = SM; the formatting is odd in the audit log. Here's what that condition actually looks like:
condition.png

 

And here's the DE issue with the linked SM issue visible:

linkedIssue.png

1 answer

1 accepted

1 vote
Answer accepted
Yvan Martin
Atlassian Team
Atlassian Team members are employees working across the company in a wide variety of roles.
January 15, 2020

Developer from Automation here.

You should just need to swap out your Related issues condition for a regular Issue fields condition or Advanced issue condition. The reason being is Related issue condition is actually ran on all the linked issues, so in your example that rule will be executed as following:

Issue transition on project DE
Branch on issues linked to DE
    Then run related issues condition on the issues that are linked to DE

Where as you just want to do the condition on the issues linked to DE, rather than the issues linked to those issues. Related issues condition is usually used at the top level of a rule, but it's less useful here since it's more about checking all the related issues match a certain condition at the top level, but you want to execute over linked issues that are part of the SM project.

Replacing related issue condition with a Issue fields condition like this should do the trick:
Screen Shot 2020-01-16 at 10.01.14 am.png





Esther Strom
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
January 16, 2020

Thank you so much! That did it. This is a super-useful plugin, and I'm really glad that Atlassian purchased it; hoping that at some point the functionality will be native.

Like Yvan Martin likes this

Suggest an answer

Log in or Sign up to answer
TAGS
AUG Leaders

Atlassian Community Events