aboutsummaryrefslogtreecommitdiffstats
path: root/extensions
diff options
context:
space:
mode:
authorFrancisco Donalisio <francsd@linux.vnet.ibm.com>2012-03-09 15:04:11 -0500
committerDave Lawrence <dlawrence@mozilla.com>2012-03-09 15:04:11 -0500
commit19e709e51b9be52b90bc16f27eaf323be475fe69 (patch)
tree865940c6a23ea1b34c9312d4823e21e5a93cc226 /extensions
parent823edaec39342c46147a60bd0a1038b392ad60fa (diff)
downloadbugs-19e709e51b9be52b90bc16f27eaf323be475fe69.tar
bugs-19e709e51b9be52b90bc16f27eaf323be475fe69.tar.gz
bugs-19e709e51b9be52b90bc16f27eaf323be475fe69.tar.bz2
bugs-19e709e51b9be52b90bc16f27eaf323be475fe69.tar.xz
bugs-19e709e51b9be52b90bc16f27eaf323be475fe69.zip
Bug 730794 - Need new hook edituser page
r=dkl, a=LpSolit
Diffstat (limited to 'extensions')
-rw-r--r--extensions/Example/Extension.pm14
1 files changed, 14 insertions, 0 deletions
diff --git a/extensions/Example/Extension.pm b/extensions/Example/Extension.pm
index 4c2d51336..a2ab3b5fc 100644
--- a/extensions/Example/Extension.pm
+++ b/extensions/Example/Extension.pm
@@ -807,6 +807,20 @@ sub bug_check_can_change_field {
}
}
+sub admin_editusers_action {
+ my ($self, $args) = @_;
+ my ($vars, $action, $user) = @$args{qw(vars action user)};
+ my $template = Bugzilla->template;
+
+ if ($action eq 'my_action') {
+ # Allow to restrict the search to any group the user is allowed to bless.
+ $vars->{'restrictablegroups'} = $user->bless_groups();
+ $template->process('admin/users/search.html.tmpl', $vars)
+ || ThrowTemplateError($template->error());
+ exit;
+ }
+}
+
sub user_preferences {
my ($self, $args) = @_;
my $tab = $args->{current_tab};