From dc4d9cf87bda5fb715a85fe30f035082789ec1bf Mon Sep 17 00:00:00 2001 From: miker Date: Mon, 17 Aug 2009 14:30:01 +0000 Subject: [PATCH] add "distinct" support to fielder git-svn-id: svn://svn.open-ils.org/ILS/trunk@13845 dcc99617-32d9-48b4-a31d-7c20da2025e4 --- Open-ILS/src/perlmods/OpenILS/Application/Fielder.pm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/Open-ILS/src/perlmods/OpenILS/Application/Fielder.pm b/Open-ILS/src/perlmods/OpenILS/Application/Fielder.pm index c541345dd..4703add92 100644 --- a/Open-ILS/src/perlmods/OpenILS/Application/Fielder.pm +++ b/Open-ILS/src/perlmods/OpenILS/Application/Fielder.pm @@ -60,6 +60,7 @@ sub fielder_fetch { my $query = $obj->{query}; my $fields = $obj->{fields}; + my $distinct = $obj->{distinct} ? 1 : 0; my $obj_class = $self->{class_hint}; my $fm_class = $self->{class_name}; @@ -82,7 +83,8 @@ sub fielder_fetch { my $res = new_editor()->json_query({ select => { $obj_class => $fields }, from => $obj_class, - where => $query + where => $query, + distinct=> $distinct }); for my $value (@$res) { -- 2.11.0