I have a requirement to have two custom single select fields with the same set of options. I know under the JIRA hood, the option names may be the same but the option ids are different. The fields are used at different parts of the process but have the same set of options. The list is contains over 20 options and I would really like to only maintain one list of options used by both fields?
I've been experimenting with the Behavior addon and some groovy scripting but not much luck. I've been able to limit the selection of options at different parts in the workflow process but that means initially creating a custom select field with all the options defined and then use the script to limit which options are visible. I really want to create a dynamic list of option via some functionality in ScriptRunner/Behavior
I'm running JIRA 6.4 and ScriptRunner 3.0.11. Any ideas?
Community moderators have prevented the ability to post new answers.
you could use the "database customfield plugin" to do and have two dbcf customfields that use the same set of options.
https://marketplace.atlassian.com/plugins/com.keplerrominfo.jira.plugins.databasecf
Interesting but I was hoping to solve my problem with my existing ScriptRunner plugin.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
I think that the problem you will find with that is that you still need two separate option lists since script-runner requires valid ID, VALUE pairs for that field. I don't think that there is any way around that if using the built in Select list.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
What I would have suggested is a custom listener that listens for com.atlassian.jira.event.issue.field.CustomFieldUpdatedEvent. If it's the right field, it syncs the options to the other field.
However, modifying the options doesn't fire that event, apparently.
Generally we do this kind of thing through a script, that could update the options in both fields. As Jeff said, they can't be the same option.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Too bad, thanks for your reply.
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.