diff options
Diffstat (limited to 'rt/share/html/Elements/EditCustomFieldCombobox')
-rw-r--r-- | rt/share/html/Elements/EditCustomFieldCombobox | 13 |
1 files changed, 11 insertions, 2 deletions
diff --git a/rt/share/html/Elements/EditCustomFieldCombobox b/rt/share/html/Elements/EditCustomFieldCombobox index 718ff3035..28fc2a1f4 100644 --- a/rt/share/html/Elements/EditCustomFieldCombobox +++ b/rt/share/html/Elements/EditCustomFieldCombobox @@ -46,17 +46,25 @@ %# %# END BPS TAGGED BLOCK }}} % while ($Values and my $value = $Values->Next and $Multiple) { -<input type="checkbox" class="checkbox CF-<%$CustomField->id%>-Edit" name="<%$NamePrefix%><%$CustomField->Id%>-DeleteValueIds" class="CF-<%$CustomField->id%>-Edit" value="<% $value->Id %>" /><% $value->Content %> +<input type="checkbox" id="<%$delete_name%>" class="checkbox CF-<%$CustomField->id%>-Edit" name="<%$delete_name%>" class="CF-<%$CustomField->id%>-Edit" value="<% $value->Id %>" /> +<label for="<%$delete_name%>"><% $value->Content %></label> <br /> % } % (!$Multiple or !$MaxValues or !$Values or $Values->Count < $MaxValues) or return; <& /Widgets/ComboBox, - Name => $NamePrefix . $CustomField->Id . "-Value", + Name => $name, Default => $Default, Rows => $Rows, Class => "CF-".$CustomField->id."-Edit", Values => [map {$_->Name} @{$CustomField->Values->ItemsArrayRef}], &> + +<%INIT> +my $name = $Name || $NamePrefix . $CustomField->Id . '-Value'; +my $delete_name = $name; +$delete_name =~ s!-Value$!-DeleteValueIds!; +</%INIT> + <%ARGS> $Object => undef $CustomField => undef @@ -66,4 +74,5 @@ $Values => undef $Multiple => 0 $Rows => undef $MaxValues => undef +$Name => undef </%ARGS> |