Bug 5104: Add control number as search option to acq z39.50 search github/bug_5104 origin/new/enh/bug_5104
authorKatrin Fischer <Katrin.Fischer.83@web.de>
Thu, 2 Dec 2010 12:45:13 +0000 (12:45 +0000)
committerChris Cormack <chrisc@catalyst.net.nz>
Thu, 2 Dec 2010 23:32:32 +0000 (12:32 +1300)
Adds control number as search option to z39.50 search in acquisitions.

Signed-off-by: Marcel de Rooy <m.de.rooy@rijksmuseum.nl>
Signed-off-by: Chris Cormack <chrisc@catalyst.net.nz>
acqui/z3950_search.pl
koha-tmpl/intranet-tmpl/prog/en/modules/acqui/z3950_search.tmpl

index 182e121..b0a8b92 100755 (executable)
@@ -57,6 +57,7 @@ my $lccn          = $input->param('lccn');
 my $lccall          = $input->param('lccall');
 my $subject= $input->param('subject');
 my $dewey = $input->param('dewey');
+my $controlnumber      = $input->param('controlnumber');
 my $op            = $input->param('op');
 my $booksellerid = $input->param('booksellerid');
 my $basketno = $input->param('basketno');
@@ -118,6 +119,7 @@ if ( $op ne "do_search" ) {
         lccall       => $lccall,
         title        => $title,
         author       => $author,
+        controlnumber=> $controlnumber,
         serverloop   => $serverloop,
         opsearch     => "search",
         biblionumber => $biblionumber,
@@ -164,6 +166,10 @@ else {
         $query .= " \@attr 1=16 \@attr 2=3 \@attr 3=1 \@attr 4=1 \@attr 5=1 \@attr 6=1 \"$lccall\" ";
         $nterms++;
     }
+    if ($controlnumber) {
+        $query .= " \@attr 1=12 \"$controlnumber\" ";
+        $nterms++;
+    }
 for my $i (1..$nterms-1) {
     $query = "\@and " . $query;
 }
index 2219dfa..063520c 100644 (file)
@@ -75,7 +75,9 @@ tr.selected { background-color : #FFFFCC; } tr.selected td { background-color :
            <fieldset class="rows">
                 <ol><li><label for="searchtitle">Title: </label> <input type="text" id="searchtitle"  name="title" value="<!-- TMPL_VAR NAME="title" ESCAPE="html" -->" /></li>
                 <li><label for="isbn">ISBN/ISSN: </label> <input type="text" id="isbn" name="isbn" value="<!-- TMPL_VAR NAME="isbn" -->" /></li>
-                <li><label for="lccall">LC Call Number: </label> <input type="text" id="lccall" name="lccall" value="" /></li></ol>
+                <li><label for="lccall">LC Call Number: </label> <input type="text" id="lccall" name="lccall" value="" /></li>
+         <li><label for="controlnumber">Control No.: </label> <input type="text" id="controlnumber" name="controlnumber" value="" /></li>
+</ol>
                </fieldset>
            </div>
     <div class="yui-u">