Just a heads up: On March 24, 2025, starting at 4:30pm CDT / 19:30 UTC, the site will be undergoing scheduled maintenance for a few hours. During this time, the site might be unavailable for a short while. Thanks for your patience.

×
Create
cancel
Showing results for 
Search instead for 
Did you mean: 
Sign up Log in

Automation for Jira and "sub-rules"?

David Loszewski
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.
June 12, 2023

Has anyone found a way to create "sub-rules" for those tasks that are reused in more than one Automation for Jira rule? It would be super useful to be able to call an excerpt/sub-rule that you already have in place instead of having to retype it all.  

1 answer

0 votes
Mark Segall
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 12, 2023

Hi @David Loszewski - Under rule details, you can select to allow other rules to trigger.  If you have a specific example of what you're trying to achieve, please provide it so we can help further.

David Loszewski
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.
June 12, 2023

How would I trigger it though?  

 

Example I have:

During a workflow, once it reaches a certain step, it will create an issue and copy certain fields over from the trigger issue.  These fields vary in range from 20 to 50 fields depending on the issue type.  

I would like to take "edit issue fields" and either copy it to another automation rule or be able to call it from another rule so I don't have to duplicate my efforts.  

 

Ideally I'd like to take that edit issues fields action and place it into a manual trigger rule and then be able to call upon that rule. 

Mark Segall
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
June 12, 2023

For your example, is there a reason that you're using the Create Issue action vs Clone Issue?  My interpretation is that you probably have more fields being copied than not so you could use clone and then explicitly set the exceptions on the fields you don't want copied over.  This should make your rule less challenging.

Otherwise, you would want to do something like this:

RULE #1 - Create Issue

  • TRIGGER: Issue Transitioned
  • ACTION: Create Issue
    • Linked Issues (Link to the trigger issue so subsequent rules can find the original issue)

RULE #n - Edit Issues

This is where you'd set up your children rules that are allowed to trigger from other rules.  They would work something like this:

  • TRIGGER: Issue Created
  • CONDITION: Linked Issues are present
  • CONDITION: Issue Type = x
  • ACTION: Lookup Issues
    You would search for the original trigger issue here with something like this:
    • isBlockedBy = {{issue}}
  • ACTION: Edit Issue
    Configure the issue to copy from the Lookup Issue results above
    • Field x
      • {{lookupIssues.Field x}}

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