diff options
author | Ivan Kohler <ivan@freeside.biz> | 2012-09-23 14:56:51 -0700 |
---|---|---|
committer | Ivan Kohler <ivan@freeside.biz> | 2012-09-23 14:56:51 -0700 |
commit | 0bff2e665b3a6389b47510e4c04a5a454f6dd7d4 (patch) | |
tree | e7f3368c067594b98699c5cf62f0991e8ceb2e4f /rt/share/html/Elements/QueueSummaryByStatus | |
parent | 806d426d106efea2b2b13314108c4ac046511e1c (diff) |
rt 4.0.7
Diffstat (limited to 'rt/share/html/Elements/QueueSummaryByStatus')
-rw-r--r-- | rt/share/html/Elements/QueueSummaryByStatus | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/rt/share/html/Elements/QueueSummaryByStatus b/rt/share/html/Elements/QueueSummaryByStatus index 09f274f74..f649d2850 100644 --- a/rt/share/html/Elements/QueueSummaryByStatus +++ b/rt/share/html/Elements/QueueSummaryByStatus @@ -122,9 +122,13 @@ my $statuses = {}; use RT::Report::Tickets; my $report = RT::Report::Tickets->new( RT->SystemUser ); -my $query = @queues - ? join(' OR ', map "Queue = ".$_->{id}, @queues) - : 'id < 0'; +my $query = + "(". + join(" OR ", map {s{(['\\])}{\\$1}g; "Status = '$_'"} @statuses) #' + .") AND (". + join(' OR ', map "Queue = ".$_->{id}, @queues) + .")"; +$query = 'id < 0' unless @queues; $report->SetupGroupings( Query => $query, GroupBy => [qw(Status Queue)] ); while ( my $entry = $report->Next ) { |