From 5a88e58bfacb0b8ee949fa96e7069db8182fa353 Mon Sep 17 00:00:00 2001 From: berick Date: Wed, 20 Apr 2011 11:20:46 -0400 Subject: [PATCH] pre-svf mattype filter (well, facet) handing for kcls; --- .../perlmods/lib/OpenILS/WWW/EGCatLoader/Search.pm | 10 +++++++++- 1 files changed, 9 insertions(+), 1 deletions(-) diff --git a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Search.pm b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Search.pm index 272a3fc..ccdf415 100644 --- a/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Search.pm +++ b/Open-ILS/src/perlmods/lib/OpenILS/WWW/EGCatLoader/Search.pm @@ -54,7 +54,13 @@ sub _prepare_biblio_search { foreach (grep /^fi:/, $cgi->param) { /:(\w+)$/ or next; my $term = join(",", $cgi->param($_)); - $query .= " $1($term)" if length $term; + next unless length $term; + if($_ eq 'fi:format') { + # XXX pre-svf KCLS mattype filtering... + $query .= " identifier|mattype[$term]"; + } else { + $query .= " $1($term)"; + } } if ($cgi->param('sort')) { @@ -116,6 +122,8 @@ sub load_rresults { $query = "$query $facet" if $facet; # TODO + $logger->activity("EGWeb: [search] $query"); + my $results; try { -- 1.7.2.5