[Rt-commit] r12939 - in rt/branches/3.6-RELEASE: html/Elements
ruz at bestpractical.com
ruz at bestpractical.com
Thu Jun 5 17:09:11 EDT 2008
Author: ruz
Date: Thu Jun 5 17:09:11 2008
New Revision: 12939
Modified:
rt/branches/3.6-RELEASE/html/Elements/ShowSearch
rt/branches/3.6-RELEASE/lib/RT/Tickets_Overlay_SQL.pm
Log:
* move replacement of __CurrentUser__ deeper in the code
** now it's possible it use it query builder
** you can give people links to searches by their id
Modified: rt/branches/3.6-RELEASE/html/Elements/ShowSearch
==============================================================================
--- rt/branches/3.6-RELEASE/html/Elements/ShowSearch (original)
+++ rt/branches/3.6-RELEASE/html/Elements/ShowSearch Thu Jun 5 17:09:11 2008
@@ -111,7 +111,6 @@
);
foreach ( $SearchArg, $ProcessedSearchArg ) {
- $_->{'Query'} =~ s/__CurrentUser__/$session{'CurrentUser'}->Id/ge;
$_->{'Format'} =~ s/__WebPath__/$RT::WebPath/g;
$_->{'Format'} =~ s/__loc\(["']?(\w+)["']?\)__/loc("$1")/ge;
}
Modified: rt/branches/3.6-RELEASE/lib/RT/Tickets_Overlay_SQL.pm
==============================================================================
--- rt/branches/3.6-RELEASE/lib/RT/Tickets_Overlay_SQL.pm (original)
+++ rt/branches/3.6-RELEASE/lib/RT/Tickets_Overlay_SQL.pm Thu Jun 5 17:09:11 2008
@@ -290,6 +290,9 @@
$key =~ s!\\(.)!$1!g;
$val =~ s!\\(.)!$1!g;
# print "$ea Key=[$key] op=[$op] val=[$val]\n";
+
+ # replace __CurrentUser__ with id
+ $val = $self->CurrentUser->id if $val eq '__CurrentUser__';
my $subkey = '';
More information about the Rt-commit
mailing list