[Rt-commit] rt branch, 4.2-trunk, updated. rt-4.2.3-184-g40da570
Alex Vandiver
alexmv at bestpractical.com
Thu May 1 16:56:05 EDT 2014
The branch, 4.2-trunk has been updated
via 40da5706462d1c3a8bfe670567f4a0e84aebe772 (commit)
via 55333243d7fbf036acc1ac15bd5d86feae60d52d (commit)
from 0ff8b869373aee71337e7c172e699172df3bfaaa (commit)
Summary of changes:
share/html/Elements/SelectOwnerDropdown | 6 ++++--
1 file changed, 4 insertions(+), 2 deletions(-)
- Log -----------------------------------------------------------------
commit 55333243d7fbf036acc1ac15bd5d86feae60d52d
Author: Christian Loos <cloos at netcologne.de>
Date: Tue Apr 29 17:24:33 2014 +0200
fix owner dropdown warning for ticket search without queue clause
3056568 introduced switching to autocompleter if we have more than 50 owners.
The commit missed that Search/Build.html (Search/Elements/PickBasics) also use
the SelectOwner element and pass an empty Queues hash, if the query doesn't have
a queue clause (which is the case if you create a new ticket search).
In the above case the SelectOwner element pass an empty queue object as Objects
to the SelectOwnerDropdown which results in loading every user with OwnTicket
rights.
This commit fixes "Use of uninitialized value in concatenation" warnings on
ticket search without a queue clause in the query.
It also avoids the "More than 50 possible Owners found ..." notice on new
ticket search if you have more than 50 users with the OwnTicket right.
diff --git a/share/html/Elements/SelectOwnerDropdown b/share/html/Elements/SelectOwnerDropdown
index 977133a..73d0d52 100644
--- a/share/html/Elements/SelectOwnerDropdown
+++ b/share/html/Elements/SelectOwnerDropdown
@@ -83,8 +83,10 @@ my $dropdown_limit = 50;
$m->callback( CallbackName => 'ModifyDropdownLimit', DropdownLimit => \$dropdown_limit );
if (keys(%user_uniq_hash) > $dropdown_limit ) {
- my $desc = $Objects->[0]->RecordType." ".$Objects->[0]->id;
- RT->Logger->notice("More than $dropdown_limit possible Owners found for $desc; switching to autocompleter");
+ if ($Objects->[0]->id) {
+ my $desc = $Objects->[0]->RecordType." ".$Objects->[0]->id;
+ RT->Logger->notice("More than $dropdown_limit possible Owners found for $desc; switching to autocompleter");
+ }
$m->comp("/Elements/SelectOwnerAutocomplete", %ARGS);
return;
}
commit 40da5706462d1c3a8bfe670567f4a0e84aebe772
Merge: 0ff8b86 5533324
Author: Alex Vandiver <alexmv at bestpractical.com>
Date: Thu May 1 16:54:19 2014 -0400
Merge branch '4.2/fix-owner-dropdown-warning' into 4.2-trunk
-----------------------------------------------------------------------
More information about the rt-commit
mailing list