I seem to have no if/else block option in our Jira automation function. Why is that, please?
Hello @Phil Bustin
Please show us the entire rule you have and where you are trying to insert the If/Else.
There are limitations to where it can be used. I believe it can't be used within a Branch, for example.
I found if/else, by starting to create a new rule. When I clicked before the branch in the existing rule, I still didn’t see it, so I guess an existing rule precludes if/else if there’s a branch, period. I’m still not clear on why I needed a branch in the first place. Perhaps it’s unavoidable:
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Having a branch doesn't preclude inserting If/Else before the branch.
Since you haven't told us anything about what you want to do with your rule I can't speak to why you need a branch.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
The answer to your question is interesting but simple: I used as my model a Community post on transitioning the parent when all sub-tasks are done:
Somehow, I thought I'd see the if/else option as soon as I clicked New component, but now I see that it is in the menu after I click New condition. It was hiding in plain sight, for days. :-)
Meanwhile, by copying the rule that works, and in the copy, changing within the branch the value in the condition and transition name in the action, I have a two rules that work together.
Just to know, why doesn't this attempt at a Rule with stacked conditions (that are actually mutually exclusive) within the branch work?
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Can you provide the Audit Log details for an instance where the stacked conditions version did not work?
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.
So, TAST6-783 is the subtask that triggered the rule.
TAST6-771 the parent of the subtask .
The second entry in the log indicates that it is successful in getting past the "If Sub-tasks match" component; all sub-tasks of TAST6-771 are in the status of "Dev Task Completed".
The third entry in the log indicates that is is failing on the "To Region = PA"; for TAST6-771 the To Region field is not set to PA
To achieve what I think you want you would need to restructure your rule thus:
For Parent
If sub-tasks are all "Dev Task Complete"
and Parent's To Region field is "PA"
then transition parent to PA Certification
For Parent
If sub-tasks are all "Dev Task Complete"
and Parent's To Region field is one of "BA","MO"
then transition parent to Selecting Tasks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Elegant. I created the new branch, duplicated the first condition, and dragged the other two conditions under the new branch. It works.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@Phil Bustin,
Is this inside of a branching statement by any chance? The If/Else doesn't work inside of branching statements!
Thanks,
Kian
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Please view my reply to Trudy's answer, above.
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.
That appears to be untrue.
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.
When I click "field condition" in the menu you see in my posted question, I only see:
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.