%# Natives who beat drums to drive off evil spirits are objects of
%# scorn to smart Americans who blow horns to break up traffic jams.
%# -- Mary Ellen Kelly
% if ($DoSearch) {
% require URI::Escape;
% $m->abort;
% }
<& /Edit/Elements/PopHeader, Title => loc('Query'), Action => 'Search.html' &>
<& /Edit/Elements/PopFooter &>
<%INIT>
my (@Args, $Groups);
if ($DoSearch) {
foreach my $key (sort keys %ARGS) {
next if $key =~ /^(?:user|pass|auth_digest|auth_nonce|auth_created)$/;
my $val = $ARGS{$key};
push @Args, [ $key => $_ ] foreach (ref($val) ? @$val : $val);
}
}
else {
$Groups = RT::Groups->new($session{'CurrentUser'});
$Groups->LimitToUserDefinedGroups;
$Groups->OrderBy( FIELD => 'Name', ORDER => 'DESC' );
}
%INIT>
<%ARGS>
$DoSearch => undef
%ARGS>