Hello Community,
My use case:
Make a field required based on another field's value. For example, if field A = Yes, then field C (text field) is required. If field A = No, then field C (text field) is NOT required.
Instance limitations:
Only Jira Cloud native features available; and no option to purchase add-ons (no script-runner).
Anyone been able to solve for this use case? Your help would be greatly appreciated.
Hello @Apryl Harris
What you want cannot be implemented with native Jira functionality. It requires a third party app.
A partial solution is to use Validators in Workflow transitions. You could create specific transitions for when field A is No, and when field A is Yes by setting Conditions on those transitions. On the transition with the A=Yes condition add a Validator to require an entry in field C.
That only checks when there is a status change being executed.
If a user edits Field A at another time. There is no way to require an entry in field C in real time, with native Jira functionality.
You could create an Automation Rule that would be triggered by a change of Field A to Yes. In that rule you could check if Field C has a value. If it does not you could automatically change Field A back to No and send a message to the initiator that they need to first fill in Field C and then they can change Field A to Yes.
@Trudy Claspill
The automation rule might work well enough. What would be the specific rule configuration? I initially thought of that but couldn't get it to work. I can try again.
Thank for your assistance.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Trigger: Field value changed
Field: Field A
Condition: Field value condition
Field: Field A
condition: equals
Value: Yes
Condition: Field value condition
Field: Field C
condition: is empty
Action: Edit Issue
Field: Field A
Value: No
Action: Send Email
To: Initiator
Subject: {{issue.key}} requires entry in Field C
Content:
You attempted to change Field A to Yes in {{issue.key}}.
That is not allowed without an entry in Field C.
Field A has been reverted to No.
Please make the correct entry in Field C, then change Field A to Yes.
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.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.