Lines 649-655
sub get_matches {
Link Here
|
649 |
my $total_hits; |
649 |
my $total_hits; |
650 |
if ( $self->{'record_type'} eq 'biblio' ) { |
650 |
if ( $self->{'record_type'} eq 'biblio' ) { |
651 |
|
651 |
|
652 |
if ($QParser) { |
652 |
#NOTE: The QueryParser can't handle the CCL syntax of 'qualifier','qualifier', so fallback to non-QueryParser. |
|
|
653 |
#NOTE: You can see this in C4::Search::SimpleSearch() as well in a different way. |
654 |
if ($QParser && $matchpoint->{'index'} !~ m/\w,\w/) { |
653 |
$query = join( " || ", |
655 |
$query = join( " || ", |
654 |
map { "$matchpoint->{'index'}:$_" } @source_keys ); |
656 |
map { "$matchpoint->{'index'}:$_" } @source_keys ); |
655 |
} |
657 |
} |
Lines 660-668
sub get_matches {
Link Here
|
660 |
} |
662 |
} |
661 |
|
663 |
|
662 |
require C4::Search; |
664 |
require C4::Search; |
663 |
|
|
|
664 |
( $error, $searchresults, $total_hits ) = |
665 |
( $error, $searchresults, $total_hits ) = |
665 |
C4::Search::SimpleSearch( $query, 0, $max_matches ); |
666 |
C4::Search::SimpleSearch( $query, 0, $max_matches, undef, "skip_normalize" ); |
666 |
} |
667 |
} |
667 |
elsif ( $self->{'record_type'} eq 'authority' ) { |
668 |
elsif ( $self->{'record_type'} eq 'authority' ) { |
668 |
my $authresults; |
669 |
my $authresults; |
Lines 822-828
sub _get_match_keys {
Link Here
|
822 |
} elsif ($component->{'offset'}) { |
823 |
} elsif ($component->{'offset'}) { |
823 |
$string= substr($string, $component->{'offset'}); |
824 |
$string= substr($string, $component->{'offset'}); |
824 |
} |
825 |
} |
825 |
$key = _normalize($string); |
826 |
$key = $string; |
|
|
827 |
my $norms = $component->{'norms'}; |
828 |
my $normalizer = $norms->[0]; #Matching rules, currently, can only have one normalizer. It will always be defined, even if it's only as ''. |
829 |
if ($normalizer !~ /(none|raw)/i){ |
830 |
$key = _normalize($string); |
831 |
} |
826 |
if ($i == 0) { |
832 |
if ($i == 0) { |
827 |
push @keys, $key if $key; |
833 |
push @keys, $key if $key; |
828 |
} else { |
834 |
} else { |