[open-ils-commits] r19850 - branches/rel_2_1/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg (dbwells)
svn at svn.open-ils.org
svn at svn.open-ils.org
Tue Mar 22 10:40:15 EDT 2011
Author: dbwells
Date: 2011-03-22 10:40:12 -0400 (Tue, 22 Mar 2011)
New Revision: 19850
Modified:
branches/rel_2_1/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/QueryParser.pm
Log:
Honor the 'active' flag in QueryParser.pm for search.relevance_adjustment entries.
Modified: branches/rel_2_1/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/QueryParser.pm
===================================================================
--- branches/rel_2_1/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/QueryParser.pm 2011-03-22 14:39:56 UTC (rev 19849)
+++ branches/rel_2_1/Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/QueryParser.pm 2011-03-22 14:40:12 UTC (rev 19850)
@@ -208,7 +208,11 @@
my $multiplier = shift;
my $active = shift;
- $active = 1 if (!defined($active));
+ if (defined($active) and $active eq 'f') {
+ $active = 0;
+ } else {
+ $active = 1;
+ }
$self->relevance_bumps->{$class}{$field}{$type} = { multiplier => $multiplier, active => $active };
@@ -248,7 +252,7 @@
for my $sra (@$sra_list) {
my $c = $self->search_field_class_by_id( $sra->field );
- __PACKAGE__->add_relevance_bump( $c->{classname}, $c->{field}, $sra->bump_type, $sra->multiplier );
+ __PACKAGE__->add_relevance_bump( $c->{classname}, $c->{field}, $sra->bump_type, $sra->multiplier, $sra->active );
}
return $self->relevance_bumps;
More information about the open-ils-commits
mailing list