Bugzilla – Attachment 17262 Details for
Bug 9986
Two fixes on Z3950 Search
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
[PASSED QA] Bug 9986: Two fixes for Z3950 search
PASSED-QA-Bug-9986-Two-fixes-for-Z3950-search.patch (text/plain), 3.41 KB, created by
Katrin Fischer
on 2013-04-07 17:29:15 UTC
(
hide
)
Description:
[PASSED QA] Bug 9986: Two fixes for Z3950 search
Filename:
MIME Type:
Creator:
Katrin Fischer
Created:
2013-04-07 17:29:15 UTC
Size:
3.41 KB
patch
obsolete
>From 814c82de74d7d5bc2ec9baa52f43b33799c110df Mon Sep 17 00:00:00 2001 >From: Marcel de Rooy <m.de.rooy@rijksmuseum.nl> >Date: Wed, 3 Apr 2013 16:36:25 +0200 >Subject: [PATCH] [PASSED QA] Bug 9986: Two fixes for Z3950 search > >Searching for stdid: Standard ID, srchany: RAW (any) somehow did not work >anymore. >Probably my fault :) Note that these two fields are in Cataloging Z3950 search >and not in Acquisition. > >Fixing encoding problems: When adding -utf flag for CGI in acqui/z3950 and >cataloging/z3950, the decoding statements in C4/Breeding, Z3950Search should be >removed. > >Test plan: >Search in Cataloging with: >Standard ID: 9782358670043 on LOC >RAW (any): musee [add an accent aigu on first e] on LOC -- Add diacritic!!! > >Search in Acquisition >Somewhere, does not matter, but use a diacritic. > >A note: My git version still has a hard time with utf8. Need to upgrade to version 1.7.10 to resolve this.. > >Signed-off-by: Bernardo Gonzalez Kriegel <bgkriegel@gmail.com> > >Comment: Work as described. No errors >Without patch z39.50 search for example Std ID OR musee gives no results, >with patch there are. >No problems in acq search. > >Signed-off-by: Katrin Fischer <Katrin.Fischer.83@web.de> >Good catch, passes all tests and QA script. >--- > C4/Breeding.pm | 13 ++++++++++--- > acqui/z3950_search.pl | 2 +- > cataloguing/z3950_search.pl | 4 ++-- > 3 files changed, 13 insertions(+), 6 deletions(-) > >diff --git a/C4/Breeding.pm b/C4/Breeding.pm >index 4d26be6..01aca21 100644 >--- a/C4/Breeding.pm >+++ b/C4/Breeding.pm >@@ -243,6 +243,8 @@ sub Z3950Search { > my $lccn= $pars->{lccn}; > my $lccall= $pars->{lccall}; > my $controlnumber= $pars->{controlnumber}; >+ my $srchany= $pars->{srchany}; >+ my $stdid= $pars->{stdid}; > > my $show_next = 0; > my $total_pages = 0; >@@ -280,12 +282,10 @@ sub Z3950Search { > $nterms++; > } > if ($title) { >- utf8::decode($title); > $query .= " \@attr 1=4 \"$title\" "; > $nterms++; > } > if ($author) { >- utf8::decode($author); > $query .= " \@attr 1=1003 \"$author\" "; > $nterms++; > } >@@ -294,7 +294,6 @@ sub Z3950Search { > $nterms++; > } > if ($subject) { >- utf8::decode($subject); > $query .= " \@attr 1=21 \"$subject\" "; > $nterms++; > } >@@ -310,6 +309,14 @@ sub Z3950Search { > $query .= " \@attr 1=12 \"$controlnumber\" "; > $nterms++; > } >+ if($srchany) { >+ $query .= " \@attr 1=1016 \"$srchany\" "; >+ $nterms++; >+ } >+ if($stdid) { >+ $query .= " \@attr 1=1007 \"$stdid\" "; >+ $nterms++; >+ } > for my $i (1..$nterms-1) { > $query = "\@and " . $query; > } >diff --git a/acqui/z3950_search.pl b/acqui/z3950_search.pl >index 5247d67..0ae843f 100755 >--- a/acqui/z3950_search.pl >+++ b/acqui/z3950_search.pl >@@ -21,7 +21,7 @@ > > use warnings; > use strict; >-use CGI; >+use CGI qw/-utf8/; > > use C4::Auth; > use C4::Output; >diff --git a/cataloguing/z3950_search.pl b/cataloguing/z3950_search.pl >index 05f5f2b..425a6c1 100755 >--- a/cataloguing/z3950_search.pl >+++ b/cataloguing/z3950_search.pl >@@ -106,8 +106,8 @@ my $pars= { > subject => $subject, > lccall => $lccall, > controlnumber => $controlnumber, >- stdid => 0, >- srchany => 0, >+ stdid => $stdid, >+ srchany => $srchany, > }; > Z3950Search($pars, $template); > output_html_with_http_headers $input, $cookie, $template->output; >-- >1.7.9.5
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Diff
View Attachment As Raw
Actions:
View
|
Diff
|
Splinter Review
Attachments on
bug 9986
:
17171
|
17172
|
17173
|
17258
| 17262