[Koha-patches] [PATCH] Bug 5555: Corrected search for ISBN / ISSN
Janusz Kaczmarek
januszop at gmail.com
Mon Mar 28 18:58:06 CEST 2011
---
C4/Search.pm | 5 ++---
1 files changed, 2 insertions(+), 3 deletions(-)
diff --git a/C4/Search.pm b/C4/Search.pm
index 3a86758..e7704e2 100644
--- a/C4/Search.pm
+++ b/C4/Search.pm
@@ -1117,7 +1117,6 @@ sub buildQuery {
}
# ISBN,ISSN,Standard Number, don't need special treatment
elsif ( $index eq 'nb' || $index eq 'ns' ) {
- $indexes_set++;
(
$stemming, $auto_truncation,
$weight_fields, $fuzzy_enabled,
@@ -1132,7 +1131,7 @@ sub buildQuery {
# Set default structure attribute (word list)
my $struct_attr = q{};
- unless ( $indexes_set || !$index || $index =~ /(st-|phr|ext|wrdl)/ ) {
+ unless ( $indexes_set || !$index || $index =~ /(st-|phr|ext|wrdl|nb|ns)/ ) {
$struct_attr = ",wrdl";
}
@@ -1324,7 +1323,7 @@ sub buildQuery {
# This is flawed , means we can't search anything with : in it
# if user wants to do ccl or cql, start the query with that
# $query =~ s/:/=/g;
- $query =~ s/(?<=(ti|au|pb|su|an|kw|mc)):/=/g;
+ $query =~ s/(?<=(ti|au|pb|su|an|kw|mc|nb|ns)):/=/g;
$query =~ s/(?<=(wrdl)):/=/g;
$query =~ s/(?<=(trn|phr)):/=/g;
$limit =~ s/:/=/g;
--
1.7.2.5
More information about the Koha-patches
mailing list