Hi
I need to get the selected values for a Custom Multiselect field. Had searched the forums but there is no concrete answer for the same.
Refer to
https://developer.atlassian.com/static/javadoc/jira/6.2.1/reference/com/atlassian/jira/issue/fields/CustomField.html#getValue%28com.atlassian.jira.issue.Issue%29
Multiselects will return a list of Option. You can try something like this.
CustomField customField = customFieldManager.getCustomFieldObjectByName("name_of_cf");
List<Option> options = (List<Option>) customField .getValue(issue);
Great Thanks, but how to determine the options that are actually selected by the user.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
List<Option> options = (List<Option>)cfmselect.getValue(issue);
for (int i = 0; i < options.size(); i++) {
Env=options[i] + " " + Env
}
Added the above solved the issue. Thanks
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Need your help on this.
I have the same requirement , what i need is when ever i have added something in a custom field which is a multi select in an EPIC issue , its parent(which also contains same custom fields which values , but doesnt contain all new values or unique values which are there in its child issue) should get updated with the unique value or new value in the parent issue's custom field.
I have tried with Listener , but unable to do it.
Can you help me on this code? you have created a behavior or Listener for this? can you provide help me for the code? Any help will be appreciated.
Thanks & Regards
Manas
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
In Javascript do something like this
var selectedOptions = AJS.$("your_multiselect_component").val();
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Online forums and learning are now in one easy-to-use experience.
By continuing, you accept the updated Community Terms of Use and acknowledge the Privacy Policy. Your public name, photo, and achievements may be publicly visible and available in search engines.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.