bug 2278 - fix results pagination in auth_finder

Fix same as for 2205 - the orderby parameter is
currently required for authority searches.

Also set default results per page to 20 instead of
19.

No documentation changes.

Signed-off-by: Joshua Ferraro <jmf@liblime.com>
This commit is contained in:
Galen Charlton 2008-06-26 16:16:16 -05:00 committed by Joshua Ferraro
parent 56b9c60e8d
commit d57ce0380d
2 changed files with 7 additions and 7 deletions

View file

@ -63,7 +63,7 @@ if ( $op eq "do_search" ) {
my $orderby = $query->param('orderby');
$resultsperpage = $query->param('resultsperpage');
$resultsperpage = 19 if ( !defined $resultsperpage );
$resultsperpage = 20 if ( !defined $resultsperpage );
my ( $results, $total ) =
SearchAuthorities( \@marclist, \@and_or, \@excluding, \@operator, \@value,

View file

@ -23,7 +23,7 @@ function jumpfull(page)
<!-- TMPL_INCLUDE NAME="auth-finder-search.inc" -->
<!-- TMPL_IF name="total" --><div id="resultnumber">
<!-- TMPL_IF name="displayprev" -->
<a href="auth_finder.pl?startfrom=<!-- TMPL_VAR NAME="startfromprev" -->&amp;authtypecode=<!-- TMPL_VAR name="authtypecode" --><!-- TMPL_LOOP name="searchdata"-->&amp;<!-- TMPL_VAR name="term" -->=<!-- TMPL_VAR name="val"--><!-- /TMPL_LOOP -->&amp;op=do_search&amp;type=intranet&amp;index=<!-- TMPL_VAR name="index" -->&amp;tagid=<!-- TMPL_VAR name="tagid" -->">
<a href="auth_finder.pl?startfrom=<!-- TMPL_VAR NAME="startfromprev" -->&amp;authtypecode=<!-- TMPL_VAR name="authtypecode" --><!-- TMPL_LOOP name="searchdata"-->&amp;<!-- TMPL_VAR name="term" -->=<!-- TMPL_VAR name="val"--><!-- /TMPL_LOOP -->&amp;op=do_search&amp;type=intranet&amp;index=<!-- TMPL_VAR name="index" -->&amp;tagid=<!-- TMPL_VAR name="tagid" -->&amp;orderby=<!-- TMPL_VAR name="orderby" -->">
&lt;&lt;
</a>
<!-- /TMPL_IF -->
@ -31,12 +31,12 @@ function jumpfull(page)
<!-- TMPL_IF name="highlight" -->
<!-- TMPL_VAR NAME="number" -->
<!-- TMPL_ELSE -->
<a href="auth_finder.pl?startfrom=<!-- TMPL_VAR NAME="startfrom" -->&amp;authtypecode=<!-- TMPL_VAR name="authtypecode" --><!-- TMPL_LOOP name="searchdata"-->&amp;<!-- TMPL_VAR name="term" -->=<!-- TMPL_VAR name="val"--><!-- /TMPL_LOOP -->&amp;op=do_search&amp;type=intranet&amp;index=<!-- TMPL_VAR name="index" -->&amp;tagid=<!-- TMPL_VAR name="tagid" -->">
<a href="auth_finder.pl?startfrom=<!-- TMPL_VAR NAME="startfrom" -->&amp;authtypecode=<!-- TMPL_VAR name="authtypecode" --><!-- TMPL_LOOP name="searchdata"-->&amp;<!-- TMPL_VAR name="term" -->=<!-- TMPL_VAR name="val"--><!-- /TMPL_LOOP -->&amp;op=do_search&amp;type=intranet&amp;index=<!-- TMPL_VAR name="index" -->&amp;tagid=<!-- TMPL_VAR name="tagid" -->>&amp;orderby=<!-- TMPL_VAR name="orderby" -->">
<!-- TMPL_VAR NAME="number" --></a>
<!-- /TMPL_IF -->
<!-- /TMPL_LOOP -->
<!-- TMPL_IF name="displaynext" -->
<a href="auth_finder.pl?startfrom=<!-- TMPL_VAR NAME="startfromnext" -->&amp;authtypecode=<!-- TMPL_VAR name="authtypecode" --><!-- TMPL_LOOP name="searchdata"-->&amp;<!-- TMPL_VAR name="term" -->=<!-- TMPL_VAR name="val"--><!-- /TMPL_LOOP -->&amp;op=do_search&amp;type=intranet&amp;index=<!-- TMPL_VAR name="index" -->&amp;tagid=<!-- TMPL_VAR name="tagid" -->">
<a href="auth_finder.pl?startfrom=<!-- TMPL_VAR NAME="startfromnext" -->&amp;authtypecode=<!-- TMPL_VAR name="authtypecode" --><!-- TMPL_LOOP name="searchdata"-->&amp;<!-- TMPL_VAR name="term" -->=<!-- TMPL_VAR name="val"--><!-- /TMPL_LOOP -->&amp;op=do_search&amp;type=intranet&amp;index=<!-- TMPL_VAR name="index" -->&amp;tagid=<!-- TMPL_VAR name="tagid" -->>&amp;orderby=<!-- TMPL_VAR name="orderby" -->">
&gt;&gt;</a>
<!-- /TMPL_IF -->
<div>
@ -76,7 +76,7 @@ function jumpfull(page)
</div>
<div id="resultnumber">
<!-- TMPL_IF name="displayprev" -->
<a href="auth_finder.pl?startfrom=<!-- TMPL_VAR NAME="startfromprev" -->&amp;authtypecode=<!-- TMPL_VAR name="authtypecode" --><!-- TMPL_LOOP name="searchdata"-->&amp;<!-- TMPL_VAR name="term" -->=<!-- TMPL_VAR name="val"--><!-- /TMPL_LOOP -->&amp;op=do_search&amp;type=intranetamp;&amp;index=<!-- TMPL_VAR name="index" -->&amp;tagid=<!-- TMPL_VAR name="tagid" -->">
<a href="auth_finder.pl?startfrom=<!-- TMPL_VAR NAME="startfromprev" -->&amp;authtypecode=<!-- TMPL_VAR name="authtypecode" --><!-- TMPL_LOOP name="searchdata"-->&amp;<!-- TMPL_VAR name="term" -->=<!-- TMPL_VAR name="val"--><!-- /TMPL_LOOP -->&amp;op=do_search&amp;type=intranetamp;&amp;index=<!-- TMPL_VAR name="index" -->&amp;tagid=<!-- TMPL_VAR name="tagid" -->>&amp;orderby=<!-- TMPL_VAR name="orderby" -->">
&lt;&lt;
</a>
<!-- /TMPL_IF -->
@ -84,12 +84,12 @@ function jumpfull(page)
<!-- TMPL_IF name="highlight" -->
<!-- TMPL_VAR NAME="number" -->
<!-- TMPL_ELSE -->
<a href="auth_finder.pl?startfrom=<!-- TMPL_VAR NAME="startfrom" -->&amp;authtypecode=<!-- TMPL_VAR name="authtypecode" --><!-- TMPL_LOOP name="searchdata"-->&amp;<!-- TMPL_VAR name="term" -->=<!-- TMPL_VAR name="val"--><!-- /TMPL_LOOP -->&amp;op=do_search&amp;type=intranet&amp;index=<!-- TMPL_VAR name="index" -->&amp;tagid=<!-- TMPL_VAR name="tagid" -->">
<a href="auth_finder.pl?startfrom=<!-- TMPL_VAR NAME="startfrom" -->&amp;authtypecode=<!-- TMPL_VAR name="authtypecode" --><!-- TMPL_LOOP name="searchdata"-->&amp;<!-- TMPL_VAR name="term" -->=<!-- TMPL_VAR name="val"--><!-- /TMPL_LOOP -->&amp;op=do_search&amp;type=intranet&amp;index=<!-- TMPL_VAR name="index" -->&amp;tagid=<!-- TMPL_VAR name="tagid" -->>&amp;orderby=<!-- TMPL_VAR name="orderby" -->">
<!-- TMPL_VAR NAME="number" --></a>
<!-- /TMPL_IF -->
<!-- /TMPL_LOOP -->
<!-- TMPL_IF name="displaynext" -->
<a href="auth_finder.pl?startfrom=<!-- TMPL_VAR NAME="startfromnext" -->&amp;authtypecode=<!-- TMPL_VAR name="authtypecode" --><!-- TMPL_LOOP name="searchdata"-->&<!-- TMPL_VAR name="term" -->=<!-- TMPL_VAR name="val"--><!-- /TMPL_LOOP -->&amp;op=do_search&amp;type=intranet&amp;index=<!-- TMPL_VAR name="index" -->&amp;tagid=<!-- TMPL_VAR name="tagid" -->">
<a href="auth_finder.pl?startfrom=<!-- TMPL_VAR NAME="startfromnext" -->&amp;authtypecode=<!-- TMPL_VAR name="authtypecode" --><!-- TMPL_LOOP name="searchdata"-->&<!-- TMPL_VAR name="term" -->=<!-- TMPL_VAR name="val"--><!-- /TMPL_LOOP -->&amp;op=do_search&amp;type=intranet&amp;index=<!-- TMPL_VAR name="index" -->&amp;tagid=<!-- TMPL_VAR name="tagid" -->>&amp;orderby=<!-- TMPL_VAR name="orderby" -->">
&gt;&gt;</a>
<!-- /TMPL_IF -->
</div><!-- /TMPL_IF -->