[freeside-commits] branch FREESIDE_2_3_BRANCH updated. 1534a6ede9b49f7c268cc58c172ca7044ad4b4b7
Ivan
ivan at 420.am
Thu Mar 8 17:07:19 PST 2012
The branch, FREESIDE_2_3_BRANCH has been updated
via 1534a6ede9b49f7c268cc58c172ca7044ad4b4b7 (commit)
from 6c10ac1711ffc9d27985530d0ea39e343bc4587a (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 1534a6ede9b49f7c268cc58c172ca7044ad4b4b7
Author: Ivan Kohler <ivan-debian at 420.am>
Date: Thu Mar 8 17:07:18 2012 -0800
fix "Add package columns" in advanced customer report under MySQL, RT#16214
diff --git a/FS/FS/cust_main/Search.pm b/FS/FS/cust_main/Search.pm
index 4da516b..c5b5ff6 100644
--- a/FS/FS/cust_main/Search.pm
+++ b/FS/FS/cust_main/Search.pm
@@ -750,7 +750,7 @@ sub search {
if ($params->{'flattened_pkgs'}) {
- my $pkg_join = '';
+ #my $pkg_join = '';
if ($dbh->{Driver}->{Name} eq 'Pg') {
@@ -759,13 +759,14 @@ sub search {
} elsif ($dbh->{Driver}->{Name} =~ /^mysql/i) {
push @select, "GROUP_CONCAT(part_pkg.pkg SEPARATOR '|') as magic";
$addl_from .= ' LEFT JOIN cust_pkg USING ( custnum ) '; #Pg too w/flatpkg?
- $pkg_join .= ' LEFT JOIN part_pkg USING ( pkgpart ) ';
+ $addl_from .= ' LEFT JOIN part_pkg USING ( pkgpart ) ';
+ #$pkg_join .= ' LEFT JOIN part_pkg USING ( pkgpart ) ';
} else {
warn "warning: unknown database type ". $dbh->{Driver}->{Name}.
"omitting packing information from report.";
}
- my $header_query = "SELECT COUNT(cust_pkg.custnum = cust_main.custnum) AS count FROM cust_main $addl_from $pkg_join $extra_sql $pkgwhere group by cust_main.custnum order by count desc limit 1";
+ my $header_query = "SELECT COUNT(cust_pkg.custnum = cust_main.custnum) AS count FROM cust_main $addl_from $extra_sql $pkgwhere group by cust_main.custnum order by count desc limit 1";
my $sth = dbh->prepare($header_query) or die dbh->errstr;
$sth->execute() or die $sth->errstr;
-----------------------------------------------------------------------
Summary of changes:
FS/FS/cust_main/Search.pm | 7 ++++---
1 files changed, 4 insertions(+), 3 deletions(-)
More information about the freeside-commits
mailing list