From e394756f42902de5eade4f6738127c25fa2bcef7 Mon Sep 17 00:00:00 2001 From: "ghendricks%novell.com" <> Date: Fri, 17 Jul 2009 22:40:09 +0000 Subject: Bug 456743 - Add the ability to disable field values (mark them as inactive) patch by ghendricks@novell.com r=LpSolit, a=LpSolit --- template/en/default/admin/fieldvalues/edit.html.tmpl | 13 ++++++++++++- template/en/default/admin/fieldvalues/list.html.tmpl | 5 +++++ template/en/default/bug/field.html.tmpl | 2 +- template/en/default/search/form.html.tmpl | 14 ++++++++------ 4 files changed, 26 insertions(+), 8 deletions(-) (limited to 'template/en/default') diff --git a/template/en/default/admin/fieldvalues/edit.html.tmpl b/template/en/default/admin/fieldvalues/edit.html.tmpl index b01415577..5650ee87b 100644 --- a/template/en/default/admin/fieldvalues/edit.html.tmpl +++ b/template/en/default/admin/fieldvalues/edit.html.tmpl @@ -81,8 +81,19 @@ [% END %] + + + + [% IF value.is_default %] + This value is selected as default in the parameters for this field. It cannot be disabled. + [% ELSIF value.is_static %] + This value is non-deletable and cannot be disabled. + [% END %] + + - diff --git a/template/en/default/admin/fieldvalues/list.html.tmpl b/template/en/default/admin/fieldvalues/list.html.tmpl index fdc22d912..3f750ebca 100644 --- a/template/en/default/admin/fieldvalues/list.html.tmpl +++ b/template/en/default/admin/fieldvalues/list.html.tmpl @@ -50,6 +50,11 @@ name => "sortkey" heading => "Sortkey" }, + { + name => "isactive" + heading => "Enabled for $terms.bugs" + yesno_field => 1 + }, { name => "action" heading => "Action" diff --git a/template/en/default/bug/field.html.tmpl b/template/en/default/bug/field.html.tmpl index 21a73a805..039910f1d 100644 --- a/template/en/default/bug/field.html.tmpl +++ b/template/en/default/bug/field.html.tmpl @@ -142,7 +142,7 @@ selected="selected" [% ELSIF (control_field && control_value && !bug.${control_field.name}.contains(control_value.name)) - || (field.name == "product" && !legal_value.is_active) + || !legal_value.is_active %] class="bz_hidden_option" disabled="disabled" [% END %]> diff --git a/template/en/default/search/form.html.tmpl b/template/en/default/search/form.html.tmpl index 46df426c1..078ff8c6b 100644 --- a/template/en/default/search/form.html.tmpl +++ b/template/en/default/search/form.html.tmpl @@ -611,15 +611,17 @@ function doOnSelectProduct(selectmode) {