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

Earn badges and make progress

You're on your way to the next level! Join the Kudos program to earn points and save your progress.

Deleted user Avatar
Deleted user

Level 1: Seed

25 / 150 points

Next: Root

Avatar

1 badge earned

Collect

Participate in fun challenges

Challenges come and go, but your rewards stay with you. Do more to earn more!

Challenges
Coins

Gift kudos to your peers

What goes around comes around! Share the love by gifting kudos to your peers.

Recognition
Ribbon

Rise up in the ranks

Keep earning points to reach the top of the leaderboard. It resets every quarter so you always have a chance!

Leaderboard

Come for the products,
stay for the community

The Atlassian Community can help you and your team get more value out of Atlassian products and practices.

Atlassian Community about banner
4,466,304
Community Members
 
Community Events
176
Community Groups

Automatically clone a parent ticket including Subtasks

Edited

Trying to automate a Jira ticket

When the ticket is "Done" it automatically clones the parent ticket and subtasks.

But, the subtasks are not cloned on to the new cloned parent ticket.

In other words, I want to Clone a Task with its Subtasks. And when I click on the cloned Task, I want to have the Cloned Subtasks linked in the cloned Task, as in the original Task.

 

2 answers

1 vote

Hi @Mayur Patel and welcome to the community!

On your Clone Issue action, you need to explicitly set the issue type to sub-task.  This will present an option for where you can set the parent.  

In the end, it should look something like this:

  • TRIGGER: Issue Transitioned (Done)
  • ACTION: Clone Issue
  • ACTION: Create Variable
    • varNewParent
      {{createdIssue}}
  • BRANCH:  Sub-Tasks
    • ACTION: Clone Issue
      • Issue Type = Sub-Task 
      • Parent = {{varNewParent}}

This should do the trick

  • BRANCH:  Sub-Tasks
    • Parent = {{varNewParent}}

Silly question, where do I add this section 

Mark Segall Community Leader Dec 09, 2022

Sorry - Edited my previous post to correct my miss

I tried this before, but for some reason it only gives me 2 options

parent issue = current issue or parent issue = trigger issue

glitch.png

Mark Segall Community Leader Dec 09, 2022

You can start typing {{varNewParent}} and it will let you set it as a smart value.

It is coming up with an error

Mark Segall Community Leader Dec 09, 2022

So this is a cross-project automation?  If so, you may need to perform an Issue Create for the sub-task instead of cloning and then manually set all of the fields that you want copied over.

Hi @Mark Segall 

Thanks for your answer, creating valuables works for the same project 

I am also facing with the same issue for cross-proejct automation. 

Would you mind elaborating more detail on the resolution you mentioned or any suggested adjustment on auto setting (refer to Pic2)? 

Stuck in this stage now. 

Snipaste_2023-02-04_16-37-52.png

Snipaste_2023-02-04_16-29-27.png

Mark Segall Community Leader Feb 06, 2023

Hmm.... This looks ok on paper.  I'd take the following troubleshooting steps:

  1. Verify your variable component syntax is correct
    1. {{createdIssue}}
  2. In your branch, add a Log Action component with this to make sure it's recognizing the key for the first issue created above:
    1. {{varNewParent}}

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
CLOUD
PRODUCT PLAN
PREMIUM
TAGS

Atlassian Community Events