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,558,928
Community Members
 
Community Events
184
Community Groups

I'm looking to restrict the subtask creation to less than or equal to 10 using Automation for Jira p

I'm looking to restrict the subtask creation to less than or equal to 10 using Automation for Jira plugin .Can any help me on that .

Thanks in advance .

1 answer

1 accepted

2 votes
Answer accepted
Florian Bonniec
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 11, 2023

Hi @Kotakonda_ Bhargavi 

You cannot do that using automation as automation is trigered by events. So it would required the user to create the subtask, check if there is less than 10 then delete the issue if it's not what you want to achieve I guess.

 

What you want is to prevent user to create a sub-task if there is already 10. I don't really know you want to implement such limitation but I would have try to do it using a validator from Scriptrunner for instance to achieve that.

 

Regards

@Florian Bonniec can i know how can i implement the same using script runner

Florian Bonniec
Community Leader
Community Leader
Community Leaders are connectors, ambassadors, and mentors. On the online community, they serve as thought leaders, product experts, and moderators.
May 11, 2023

Simple Script validator with this code

 

def passesCondition = true
if(issue.parentObject.getSubTaskObjects().size() >= 10){
    passesCondition = false
}
return passesCondition;

Suggest an answer

Log in or Sign up to answer
DEPLOYMENT TYPE
SERVER
VERSION
9.4.4
TAGS
AUG Leaders

Atlassian Community Events