Hi all,
I want to allow only one component to be selected in a particular workflow state in Jira Cloud.
Have you used automation or other workarounds in your projects to achieve this?
Would love to hear your approaches and examples.
Thanks in advance!
Hi All,
Answering my own question here. I just tried an automation rule to restrict only one component in a workflow state, and it worked!
If you’re interested, I can share a screenshot of the rule and how it’s configured.
Let me know!
Yes, please share a screenshot because automation rules do not restrict what is visible to a user while on a a work item in Jira.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi @John Funk You’re right - on the UI, it doesn’t prevent users from selecting multiple component values. However, once the work item is updated, the automation removes any additional values and keeps only the first one. Here is the simple automation I configured and tested. Its working as expected.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@John Funk That smart value returns only the first component assigned to an issue.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
What if it isn't the component you want to keep? Let's say you want to only allow Component ABC, but Component 123 gets entered first, and then Component ABC. The rule will not work as you intend.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@John Funk No, The condition I am checking that rule works only if component size greater than 1
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Yes, but what I just described in my previous post would return a size of 2, thus meeting the Condition. But it would keep Component 123, when your desire is to have it set to Component ABC. The Condition will not prevent that.
Also, by using the Condition you are not achieving what you want if the only Component is Component 123 - the Condition would fail and leave that value in place when you really want Component ABC.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
@John Funk My intention is for the work item form to have only one component value. For example, if I selected Backend yesterday and someone adds other components today, the rule should retain only the previously assigned component. To change the component, I must remove the existing value first and then add the new one.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
So you just want it to have one and only component, and you don't care which one it is. I misunderstood that you wanted a particular component to be selected. Thanks for the clarification.
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.