We currently have an automation that closes work items on selected projects where the work item was created 2 weeks or prior in the past, and the team field is empty.
We need to enhance the automation to check for open subtasks on the work item, and close them as well.
Hi @Suraj ,
To include subtask closure, add a Branch Rule / Related Issues → Sub-tasks after the already existing trigger and conditions, but before the action that closes the parent work item.
Within this branch, add a condition to check for open subtask, then add action to transition it to the desired closed status. Once all subtasks have been processed, the rule can continue with the existing action to close the parent work item.
You just need to add a branch into subtasks and transition them before closing the parent.
Your automation should look something like this if you want to add subtasks:
Jira will automatically look at the current parent work item and loop through all the subtasks with this, recommend testing in sandbox first before throwing into production of course.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello @Suraj
In my opinion, giving advice like that without seeing your actual automation does not really make sense.
We do not know what exactly we are supposed to tweak.
Please share some screenshots of your current automation (Blanking Personal data), so people can better understand the setup and help you optimize it.
Best,
Arkadiusz🤠
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Suraj, the branch approach already posted is right. Two details decide whether it closes every subtask or just some:
Keep the subtask branch before the parent-close action, that also satisfies any "all sub-tasks resolved" validator on the parent. Branch on sub-tasks.
If you share your subtask statuses I'll tell you whether one transition covers them.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Germán Morales _ Hiera
Could you please check this, it will work? please let me know if any thing needs to add to this
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Suraj, the structure is right and it will close subtasks. Two things decide whether it closes all of them or quietly misses some:
If you paste your subtask statuses and their workflow, I'll tell you whether a single transition to CLOSED covers them all or you need the global one.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @Germán Morales _ Hiera
here is the workflow of subtask, we are having restriction on the workflows, and aslo attached complete automation SS please check and let me know what needs to be changed here.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello @Suraj
Could you share a screenshot of the current automation setup? Once I can see how it's configured, I'll be able to suggest the exact changes needed to ensure any open subtasks are closed before the parent work item is closed.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Suraj I took a look at this as well, and Jason's suggestion is the same approach I had in mind. We can add a subtask branch to the automation, close any open subtasks first, and then close the parent work item. That should meet the requirement.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.