From 6a90104750160b087a0252d6775ce5eb61d533d5 Mon Sep 17 00:00:00 2001 From: Thomas Berezansky Date: Wed, 10 Oct 2012 16:51:36 -0400 Subject: [PATCH] Use ][ instead of # to split facets Signed-off-by: Thomas Berezansky Signed-off-by: Lebbeous Fogle-Weekley --- .../perlmods/lib/OpenILS/Application/Storage/QueryParser.pm | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/QueryParser.pm b/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/QueryParser.pm index 02deeeb10f..1aa5c76c0a 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/QueryParser.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/QueryParser.pm @@ -919,7 +919,7 @@ sub decompose { my $phrase_cleanup_re = qr/\s*(\Q$required_op\E|\Q$disallowed_op\E|\Q$and_op\E|\Q$or_op\E|\Q$group_start\E|\Q$group_end\E|\Q$float_start\E|\Q$float_end\E|\Q$modifier_tag\E|\Q$negated_op\E|:|\(|\))/; # Build the filter and modifier uber-regexps - my $facet_re = '^\s*(-?)((?:' . join( '|', @{$pkg->facet_classes}) . ')(?:\|\w+)*)\[(.+?)\]'; + my $facet_re = '^\s*(-?)((?:' . join( '|', @{$pkg->facet_classes}) . ')(?:\|\w+)*)\[(.+?)\](?!\[)'; warn ' 'x$recursing." ** Facet RE: $facet_re\n" if $self->debug; my $filter_re = '^\s*(-?)(' . join( '|', @{$pkg->filters}) . ')\(([^()]+)\)'; @@ -1123,7 +1123,7 @@ sub decompose { my $negate = ($1 eq $pkg->operator('disallowed')) ? 1 : 0; my $facet = $2; - my $facet_value = [ split '\s*#\s*', $3 ]; + my $facet_value = [ split '\s*\]\[\s*', $3 ]; $struct->new_facet( $facet => $facet_value, $negate ); $_ = $'; -- 2.43.2