Hello All,
Tried to remove None option from the single select custom field by checking the below URL. However, None option still appears in the Custom fields.
Jira Version - 7.12.3
Lines in the edit-select.vm
#disable_html_escaping()
#customControlHeader ($action $customField.id $customField.name $fieldLayoutItem.required $displayParameters $auiparams)
<select class="select cf-select" name="$customField.id" id="$customField.id">
#if (!$fieldLayoutItem || $fieldLayoutItem.required == false)
<option value="-1">$i18n.getText("common.words.none")</option>
#else
#if ( !$configs.default )
<option value="">$i18n.getText("common.words.none")</option>
#end
#end
#foreach ($option in $configs.options)
#if(!$option.disabled || $option.disabled == false || ($value && $value == $option.optionId.toString()))
<option#if ($value && $value == $option.optionId.toString()) selected="selected"#end value="$option.optionId">$cfValueEncoder.encodeForHtml($option.value)</option>
#end
#end
</select>
#customControlFooter ($action $customField.id $fieldLayoutItem.fieldDescription $displayParameters $auiparams)
Replaced it with the below lines:
<select class="select cf-select" name="$customField.id" id="$customField.id">
#end
#foreach ($option in $configs.options)
#if(!$option.disabled || $option.disabled == false || ($value && $value == $option.optionId.toString()))
<option#if ($value && $value == $option.optionId.toString()) selected="selected"#end value="$option.optionId">$cfValueEncoder.encodeForHtml($option.value)</option>
#end
</select>
Any help would be greatly upreciated.
Thanks,
Manikanta.
Is there a particular reason you don't want to make it required? If you remove the none option what is the user supposed to select? None is there so the user doesn't have to select an option, hence their selection is None.
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.