diff options
author | Dylan William Hardison <dylan@mozilla.com> | 2015-05-01 06:03:57 +0200 |
---|---|---|
committer | Dylan William Hardison <dylan@hardison.net> | 2015-05-01 06:03:57 +0200 |
commit | c3c2eccd987259a577108fd05f57dc809950b0e6 (patch) | |
tree | 44cbe5438ce68ae36d8f36c205e2e523dd3dd5db /Bugzilla/Template.pm | |
parent | 0e68998f22b847d90753daac3808bedc4500cde6 (diff) | |
download | bugzilla-c3c2eccd987259a577108fd05f57dc809950b0e6.tar.gz bugzilla-c3c2eccd987259a577108fd05f57dc809950b0e6.tar.xz |
Bug 69267: Add the ability to deactivate keywords
r/a=glob
Diffstat (limited to 'Bugzilla/Template.pm')
-rw-r--r-- | Bugzilla/Template.pm | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/Bugzilla/Template.pm b/Bugzilla/Template.pm index de72cd71a..70a8197b5 100644 --- a/Bugzilla/Template.pm +++ b/Bugzilla/Template.pm @@ -1106,11 +1106,16 @@ sub create { # Whether or not keywords are enabled, in this Bugzilla. 'use_keywords' => sub { return Bugzilla::Keyword->any_exist; }, - # All the keywords. + # All the keywords 'all_keywords' => sub { return [map { $_->name } Bugzilla::Keyword->get_all()]; }, + # All the active keywords + 'active_keywords' => sub { + return [map { $_->name } grep { $_->is_active } Bugzilla::Keyword->get_all()]; + }, + 'feature_enabled' => sub { return Bugzilla->feature(@_); }, # field_descs can be somewhat slow to generate, so we generate |