LP1744489: Location Search Limiter
authorJason Boyer <JBoyer@library.in.gov>
Sat, 20 Jan 2018 18:25:16 +0000 (13:25 -0500)
committerMike Rylander <mrylander@gmail.com>
Mon, 22 Jan 2018 15:40:22 +0000 (10:40 -0500)
search.calculate_visibility_attribute_test expects
an array for the second parameter and was getting
a plain integer (or too many parameters).

Signed-off-by: Jason Boyer <JBoyer@library.in.gov>
Signed-off-by: Mike Rylander <mrylander@gmail.com>
Open-ILS/src/perlmods/lib/OpenILS/Application/Storage/Driver/Pg/QueryParser.pm

index 6a1d872..4b45483 100644 (file)
@@ -1534,7 +1534,7 @@ sub flatten {
                     my $negate = $filter->negate ? 'TRUE' : 'FALSE';
                     my $filter_args = join(",", map(int, @{$filter->args}));
                     push @{$vis_filter{'c_attr'}},
-                        "search.calculate_visibility_attribute_test('location',$filter_args,$negate)";
+                        "search.calculate_visibility_attribute_test('location','{$filter_args}',$negate)";
                 }
 
             } elsif ($filter->name eq 'location_groups') {