55 |
my $webpac = $c->comp('Model::WebPAC'); |
my $webpac = $c->comp('Model::WebPAC'); |
56 |
|
|
57 |
my $q = $c->req->params->{$what} || |
my $q = $c->req->params->{$what} || |
58 |
$c->req->params->{all} || $c->res->output("no results"); |
$c->req->params->{all} || $c->response->body("no results"); |
59 |
|
|
60 |
|
|
61 |
$log->info("search for '$q' in $what\n"); |
$log->info("search for '$q' in $what\n"); |
84 |
|
|
85 |
$log->debug( ($#suggestions + 1) . " unique hits returned"); |
$log->debug( ($#suggestions + 1) . " unique hits returned"); |
86 |
|
|
87 |
$c->res->body( $c->prototype->auto_complete_result( \@suggestions ) ); |
$c->response->body( $c->prototype->auto_complete_result( \@suggestions ) ); |
88 |
} |
} |
89 |
|
|
90 |
|
|
107 |
|
|
108 |
$log->debug("results got params: " . Dumper( $params ) ); |
$log->debug("results got params: " . Dumper( $params ) ); |
109 |
|
|
110 |
|
if (! $params->{_page} || $params->{_page} < 1) { |
111 |
|
$params->{_page} = 1; |
112 |
|
$log->warn("fixed _page parametar to 1"); |
113 |
|
} |
114 |
|
|
115 |
my @attr; |
my @attr; |
116 |
my @words; |
my @words; |
117 |
# default operator to join fields/words |
# default operator to join fields/words |
177 |
$c->stash->{template} = 'results.tt'; |
$c->stash->{template} = 'results.tt'; |
178 |
} |
} |
179 |
|
|
180 |
=back |
=item record |
181 |
|
|
182 |
|
forwarded to C</editor/record> |
183 |
|
|
184 |
|
=cut |
185 |
|
|
186 |
|
sub record : Local { |
187 |
|
my ( $self, $c ) = @_; |
188 |
|
|
189 |
|
$c->forward( '/editor/record' ); |
190 |
|
} |
191 |
|
|
192 |
|
=back |
193 |
|
|
194 |
=head1 AUTHOR |
=head1 AUTHOR |
195 |
|
|