summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--Bugzilla/Group.pm6
-rw-r--r--template/en/default/admin/groups/list.html.tmpl12
2 files changed, 10 insertions, 8 deletions
diff --git a/Bugzilla/Group.pm b/Bugzilla/Group.pm
index 69c3f51de..0f7771efe 100644
--- a/Bugzilla/Group.pm
+++ b/Bugzilla/Group.pm
@@ -71,6 +71,11 @@ sub is_active { return $_[0]->{'isactive'}; }
#### Methods ####
###############################
+sub is_active_bug_group {
+ my $self = shift;
+ return $self->is_active && $self->is_bug_group;
+}
+
sub _rederive_regexp {
my ($self) = @_;
RederiveRegexp($self->user_regexp, $self->id);
@@ -206,6 +211,7 @@ Bugzilla::Group - Bugzilla group class.
my $description = $group->description;
my $user_reg_exp = $group->user_reg_exp;
my $is_active = $group->is_active;
+ my $is_active_bug_group = $group->is_active_bug_group;
my $group_id = Bugzilla::Group::ValidateGroupName('admin', @users);
my @groups = Bugzilla::Group->get_all;
diff --git a/template/en/default/admin/groups/list.html.tmpl b/template/en/default/admin/groups/list.html.tmpl
index 9f4f129c4..617bbd3c1 100644
--- a/template/en/default/admin/groups/list.html.tmpl
+++ b/template/en/default/admin/groups/list.html.tmpl
@@ -52,7 +52,7 @@
{name => 'userregexp'
heading => 'User RegExp'
}
- {name => 'use_for'
+ {name => 'is_active_bug_group'
heading => "Use For $terms.Bugs"
align => 'center'
}
@@ -66,15 +66,15 @@
]
%]
-[% overrides.use_for = [ {
+[% overrides.is_active_bug_group = [ {
match_value => "0"
- match_field => 'use_for'
+ match_field => 'is_active_bug_group'
override_content => 1
content => " "
},
{
match_value => "1"
- match_field => 'use_for'
+ match_field => 'is_active_bug_group'
override_content => 1
content => "X"
}]
@@ -130,10 +130,6 @@
}]
%]
-[% FOREACH group = groups %]
- [% group.use_for = (group.isactive != 0) && (group.isbuggroup) %]
-[% END %]
-
[% PROCESS admin/table.html.tmpl
columns = columns
data = groups