fixed search problems
This commit is contained in:
parent
835292986a
commit
7f93cf1979
2 changed files with 19 additions and 3 deletions
|
|
@ -282,7 +282,8 @@ sub www_view {
|
|||
map {$url .= "&languages=".WebGUI::URL::escape($_)} $session{cgi}->param('languages');
|
||||
map {$url .= "&contentTypes=".WebGUI::URL::escape($_)} $session{cgi}->param('contentTypes');
|
||||
$url .= "&paginateAfter=".$self->getValue("paginateAfter");
|
||||
my $p = WebGUI::Paginator->new(WebGUI::URL::page($url), $results, $self->getValue("paginateAfter"));
|
||||
my $p = WebGUI::Paginator->new(WebGUI::URL::page($url), $self->getValue("paginateAfter"));
|
||||
$p->setDataByArrayRef($results);
|
||||
$var{startNr} = 1;
|
||||
if($session{form}{pn}) {
|
||||
$var{startNr} = (($session{form}{pn} - 1) * $self->getValue("paginateAfter")) + 1;
|
||||
|
|
|
|||
|
|
@ -61,6 +61,21 @@ These methods are available from this package:
|
|||
|
||||
=cut
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
sub _recurseCrumbTrail {
|
||||
my ($sth, %data, $output);
|
||||
tie %data, 'Tie::CPHash';
|
||||
%data = WebGUI::SQL->quickHash("select pageId,parentId,menuTitle,urlizedTitle from page where pageId=$_[0]");
|
||||
if ($data{pageId} > 1) {
|
||||
$output .= _recurseCrumbTrail($data{parentId});
|
||||
}
|
||||
if ($data{menuTitle} ne "") {
|
||||
$output .= '<a class="crumbTrail" href="'.WebGUI::URL::gateway($data{urlizedTitle})
|
||||
.'">'.$data{menuTitle}.'</a> > ';
|
||||
}
|
||||
return $output;
|
||||
}
|
||||
|
||||
#-------------------------------------------------------------------
|
||||
|
||||
=head2 close ( )
|
||||
|
|
@ -213,8 +228,8 @@ sub getDetails {
|
|||
$data{header} = $self->highlight($data{header},undef, $options{highlightColors}) if ($options{highlight});
|
||||
$data{location} = WebGUI::URL::gateway($data{location});
|
||||
}
|
||||
# $data{crumbTrail} = WebGUI::Macro::C_crumbTrail::_recurseCrumbTrail($data{pageId}, ' > ');
|
||||
# $data{crumbTrail} =~ s/\s*>\s*$//;
|
||||
$data{crumbTrail} = _recurseCrumbTrail($data{pageId});
|
||||
$data{crumbTrail} =~ s/\s*\>\s*$//;
|
||||
push(@searchDetails, \%data);
|
||||
}
|
||||
$sth->finish;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue