Bug 21921: Add date publication year to biblio Z39.50 search form in acquisition
authorJosef Moravec <josef.moravec@gmail.com>
Tue, 11 Feb 2020 19:03:18 +0000 (19:03 +0000)
committerMartin Renvoize <martin.renvoize@ptfs-europe.com>
Mon, 17 Feb 2020 13:44:34 +0000 (13:44 +0000)
Test plan:

1) Apply the patch
2) Have a Z39.50 endpoint with attr 31 defined - Library of Congress
supports this
3) Try to find some biblio records through Z39.50 using the new field
"Publication year" in acquisition module

Signed-off-by: Michal Denar <black23@gmail.com>
Signed-off-by: Katrin Fischer <katrin.fischer.83@web.de>
Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>

acqui/z3950_search.pl
koha-tmpl/intranet-tmpl/prog/en/modules/acqui/z3950_search.tt

index 4e53186..adb9890 100755 (executable)
@@ -45,6 +45,7 @@ my $srchany         = $input->param('srchany');
 my $stdid           = $input->param('stdid');
 my $dewey           = $input->param('dewey');
 my $controlnumber   = $input->param('controlnumber');
+my $publicationyear = $input->param('publicationyear');
 my $op              = $input->param('op')||'';
 my $booksellerid    = $input->param('booksellerid');
 my $basketno        = $input->param('basketno');
@@ -82,6 +83,7 @@ $template->param(
         subject      => $subject,
         srchany      => $srchany,
         stdid        => $stdid,
+        publicationyear => $publicationyear,
 );
 
 if ( $op ne "do_search" ) {
@@ -124,6 +126,7 @@ my $pars= {
         controlnumber => $controlnumber,
         stdid => $stdid,
         srchany => $srchany,
+        publicationyear => $publicationyear,
 };
 Z3950Search($pars, $template);
 output_html_with_http_headers $input, $cookie, $template->output;
index ff5a34d..ad836fe 100644 (file)
@@ -34,6 +34,7 @@ tr.selected { background-color : #FFFFCC; } tr.selected td { background-color :
              <li><label for="issn">ISSN: </label> <input type="text" id="issn" name="issn" value="[% issn | html %]" /></li>
              <li><label for="searchtitle">Title: </label> <input type="text" id="searchtitle"  name="title" value="[% title | html %]" class="focus" /></li>
              <li><label for="author">Author: </label> <input type="text" id="author" name="author" value="[% author | html %]" /></li>
+             <li><label for="publicationyear">Publication year: </label> <input type="text" id="publicationyear" name="publicationyear" value="[% publicationyear | html %]" /></li>
              <li><label for="subject">Subject heading: </label> <input type="text" id="subject" name="subject" value="" /></li>
              <li><label for="srchany">Keyword (any): </label> <input type="text" id="srchany" name="srchany" value="" /></li>
              <li><label for="lccall">LC call number: </label> <input type="text" id="lccall" name="lccall" value="" /></li>
@@ -90,6 +91,7 @@ tr.selected { background-color : #FFFFCC; } tr.selected td { background-color :
     <p>You searched for:
         [% IF ( title ) %]<em>Title: </em><span class=term>[% title | html %]</span> [% END %]
         [% IF ( author ) %]<em>Author: </em><span class=term>[% author | html %]</span> [% END %]
+        [% IF ( publicationyear ) %]<em>Publication year: </em><span class=term>[% publicationyear | html %]</span> [% END %]
         [% IF ( isbn ) %]<em>ISBN: </em><span class=term>[% isbn | html %]</span> [% END %]
         [% IF ( issn ) %]<em>ISSN: </em><span class=term>[% issn | html %]</span> [% END %]
         [% IF ( lccall ) %]<em>LC call number: </em><span class=term>[% lccall | html %]</span> [% END %]
@@ -175,6 +177,7 @@ tr.selected { background-color : #FFFFCC; } tr.selected td { background-color :
         <input type="hidden" id="isbn" name="isbn" value="[% isbn | html %]" />
         <input type="hidden" id="lccall" name="lccall" value="[% lccall | html %]" />
         <input type="hidden" id="author" name="author" value="[% author | html %]" />
+        <input type="hidden" id="publicationyear" name="publicationyear" value="[% publicationyear | html %]" />
         <input type="hidden" id="subject" name="subject" value="[% subject | html %]" />
         <input type="hidden" id="dewey" name="dewey" value="[% dewey | html %]" />
         <input type="hidden" name="frameworkcode" value="[% frameworkcode | html %]" />