Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge branch '4.0/quicksearch-prefs-callback' into 4.0-trunk

  • Loading branch information...
commit 12d29194219ea8dce815a9acdaefb9a98331ed3c 2 parents 91c6c74 + 97ee6ca
@alexmv alexmv authored
Showing with 10 additions and 1 deletion.
  1. +10 −1 share/html/Prefs/Quicksearch.html
View
11 share/html/Prefs/Quicksearch.html
@@ -71,7 +71,16 @@
my $unwanted = $user->Preferences('QuickSearch', {});
my $Queues = RT::Queues->new($session{'CurrentUser'});
$Queues->UnLimit;
-my @queues = grep {$_->CurrentUserHasRight('ShowTicket')} @{$Queues->ItemsArrayRef};
+
+my $right = 'ShowTicket';
+$m->callback(
+ CallbackName => 'ModifyQueues',
+ Queues => \$Queues,
+ Right => \$right,
+ Unwanted => $unwanted,
+);
+
+my @queues = grep { $right ? $_->CurrentUserHasRight($right) : 1 } @{$Queues->ItemsArrayRef};
if ($ARGS{'Save'}) {
for my $queue (@queues) {
Please sign in to comment.
Something went wrong with that request. Please try again.