diff options
author | Francisco Donalisio <francsd@linux.vnet.ibm.com> | 2012-03-09 21:10:17 +0100 |
---|---|---|
committer | Dave Lawrence <dlawrence@mozilla.com> | 2012-03-09 21:10:17 +0100 |
commit | bb5c2660a9231bab025c4ad816c00f8bae13417c (patch) | |
tree | 230675197bd8563f2a5cdcdcae019da951744407 /extensions/Example | |
parent | 5a05d970d8ee3a8c18e5b3f96302a97ec45e988e (diff) | |
download | bugzilla-bb5c2660a9231bab025c4ad816c00f8bae13417c.tar.gz bugzilla-bb5c2660a9231bab025c4ad816c00f8bae13417c.tar.xz |
Bug 730794 - Need new hook edituser page
r=dkl, a=LpSolit
Diffstat (limited to 'extensions/Example')
-rw-r--r-- | extensions/Example/Extension.pm | 14 |
1 files changed, 14 insertions, 0 deletions
diff --git a/extensions/Example/Extension.pm b/extensions/Example/Extension.pm index 4498d2b22..af56b506b 100644 --- a/extensions/Example/Extension.pm +++ b/extensions/Example/Extension.pm @@ -822,6 +822,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}; |