right now I created this automation rule:
so whenever I create a new Issue of type Bug, there are also 4 subtask created.
Now, I only want to be able to move Subtask 3 into "in Progress" once Subtask 1 and Subtask 2 are set on "Done". How can I do this inside of "Automation"?
Hi @thrilos07 ,
welcome to the community!
My first thought is, why would you want to do this?
My second one is, if you want to block a transition (to in progress), you will need to add conditions to the workflow, so it wouldn't be in automation for jira.
Finally, if you want to have any relation between the subtasks, they will need to be related (directly linked) instead of just via the parent.
If I were you, I would just chain the creation of the subtaks -> make a rule that if a subtask is closed, another is created.
Hope this helps a little.
thank you for your fast response.
-My first thought is, why would you want to do this?
I want to be able to decide, when excactly I am able to access some of the Sub-Tasks. For example, if I was going to make pasta I would create an Issue which, by default, creates the Subtasks "boil water" and "cook noodles". When those two Subtasks are done, I would like to automaticaly create a new Subtask which is called "cook the sauce" or something. So I would like to have some kind of sequence related to an Issue-Type.
-My second one is, if you want to block a transition (to in progress), you will need to add conditions to the workflow, so it wouldn't be in automation for jira.
Problem with this is, that by creating an condition it would apply to all Issues/Substorys, but I just want it to be related to the Issuetype.
-make a rule that if a subtask is closed, another is created.
That is what I am currently looking into. But I can't seem to find a way to do this, since the "When"-Clause inside of Automation only refers to Issues and not Subtasks. Or am I missing something?
in response to your second point, a subtask is a special kind of issue, but an issue nonetheless, so you could "catch" the creation of a subtasks with the create issue trigger and some extra IF's.
That being said, perhaps you could look into this discussion from a while back, which provides some other insights on this matter.
So I gave up trying to block sub-tasks from moving while others are not done. Right now I am trying a workaround, where if 2 sub-tasks are set to done another 2 subtasks are getting created inside of the same issue:
But this does not work also :). Not sure what I am not doing right.
It seems like there might be a problem with the issue type checks here. Can you confirm what the audit log is saying when the rule executes? If I am understanding your situation correctly, you are wanting to fire the rule off when a sub-task of a bug is transitioned to "Done", and then check if the parent bug's sub-tasks are all Done as well. With you current rule, the first check will be checking the triggering issue's type is bug. However, the triggering issue type would be a sub-task, not a bug, so this should fail. The same goes for the check in the branch's condition as well.
Can you try changing the first condition from "Issue type equals Bug" to a Related Issues Condition, and in that check the Parent matches JQL "issuetype in ("Bug")". Then remove that part of the branch's condition (just set the branch's condition JQL to "status = Done").
Hope this helps,
according to your requirement:
Right now I am trying a workaround, where if 2 sub-tasks are set to done another 2 subtasks are getting created inside of the same issue
I was able to build a rule in my Jira Cloud which meets your requirement.
It is tested and it works - probably there is a more elegant way, you could check.
Most parts are easy, for the "If: Sub-tasks match" "resolution is not EMPTY" part the Condition is "All match specified JQL".
However, I am not sure if this is the whole picture as in this thread were other things to be discussed, also - alongside with the thread:
So - please check, overall, if everything is understood correctly and complete.