authority_tag_sf_browse() was returning unexpected results when only a small
set of authority records was loaded. This may be an indication of a corner
case, but until we sort that out the more straightforward startwith should
be used.
Also, chop the final character of the incoming search value to ensure
that an exact match is returned on page 0 instead of page -1. For example,
'Bacon, Jono.' becomes 'Bacon, Jono' for the search. (The right thing to
do, come to think of it, is probably to naco_normalize the incoming value;
perhaps next patch).
git-svn-id: svn://svn.open-ils.org/ILS/trunk@19331
dcc99617-32d9-48b4-a31d-
7c20da2025e4
my $tag = shift;
my $subfield = shift;
+
my $value = shift;
my $limit = shift || 10;
my $page = shift || 0;
+ # Chop the last character from the incoming value to return it on page 0
+ chop($value);
+
my $ref_limit = $limit;
my $offset = $limit * abs($page);
my $_storage = OpenSRF::AppSession->create( 'open-ils.cstore' );
page = 0;
}
- var url = '/opac/extras/browse/marcxml/'
+ /* temporarily use 'startwith' instead of 'browse' until browse is repaired */
+ var url = '/opac/extras/startwith/marcxml/'
+ type + '.refs'
+ '/1' // OU - currently unscoped
+ '/' + sf.toString()