From e5c824400956ca95cd753060200c4e1227269d56 Mon Sep 17 00:00:00 2001 From: Henri-Damien LAURENT Date: Mon, 30 Nov 2009 06:54:47 +0100 Subject: [PATCH] C4/Search.pm followup auto_truncation 3.0.x cherry-pick Auto_truncation is used even though exact search selected. This patch removes this side effect Conflicts solved: C4/Search.pm Cherry-picked from 3.0.x : 3287252c0 --- C4/Search.pm | 17 +++++++++++++---- 1 file changed, 13 insertions(+), 4 deletions(-) diff --git a/C4/Search.pm b/C4/Search.pm index be40b1b4ef..5007f238d3 100644 --- a/C4/Search.pm +++ b/C4/Search.pm @@ -934,10 +934,14 @@ sub buildQuery { } if ($auto_truncation){ - # join throws an error if there is a leading space - $operand =~ s/^\s+//; - $operand=~join(" ",map{ "$_*" }split (/\s+/,$operand)); - } + unless ( $index =~ /(st-|phr|ext)/ ) { + #FIXME only valid with LTR scripts + $operand=join(" ",map{ + "$_*" + }split (/\s+/,$operand)); + warn $operand if $DEBUG; + } + } # Detect Truncation my $truncated_operand; @@ -1208,7 +1212,12 @@ sub searchResults { # loop through all of the records we've retrieved for ( my $i = $offset ; $i <= $times - 1 ; $i++ ) { my $marcrecord = MARC::File::USMARC::decode( $marcresults[$i] ); +<<<<<<< HEAD:C4/Search.pm +======= + my $biblionumber; + +>>>>>>> C4/Search.pm followup auto_truncation 3.0.x cherry-pick:C4/Search.pm if ($bibliotag<10){ $fw = GetFrameworkCode($marcrecord->field($bibliotag)->data); }else{ -- 2.39.5