[freeside-commits] branch FREESIDE_4_BRANCH updated. 8ec5976a838f840f5987280deb653b97562de5fa

Mark Wells mark at 420.am
Tue Jul 14 00:03:37 PDT 2015


The branch, FREESIDE_4_BRANCH has been updated
       via  8ec5976a838f840f5987280deb653b97562de5fa (commit)
      from  2f8c8867a7f5b504070a6306adf9989283189a04 (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 8ec5976a838f840f5987280deb653b97562de5fa
Author: Mark Wells <mark at freeside.biz>
Date:   Tue Jul 14 00:00:07 2015 -0700

    fix invoice report when there are no customer classes, #37243, from #25943

diff --git a/FS/FS/Report/Table.pm b/FS/FS/Report/Table.pm
index cba968b..0a0d24a 100644
--- a/FS/FS/Report/Table.pm
+++ b/FS/FS/Report/Table.pm
@@ -901,6 +901,7 @@ sub with_classnum {
 
   $classnum = [ $classnum ] if !ref($classnum);
   @$classnum = grep /^\d+$/, @$classnum;
+  return '' if !@$classnum;
   my $in = 'IN ('. join(',', @$classnum). ')';
 
   if ( $use_override ) {
diff --git a/FS/FS/cust_bill/Search.pm b/FS/FS/cust_bill/Search.pm
index 38f11d1..925938d 100644
--- a/FS/FS/cust_bill/Search.pm
+++ b/FS/FS/cust_bill/Search.pm
@@ -232,7 +232,7 @@ sub search_sql_where {
                      ? @{ $param->{'cust_classnum'} }
                      :  ( $param->{'cust_classnum'} );
 
-    @classnum = grep /^(\d*)$/, @classnum;
+    @classnum = grep /^(\d+)$/, @classnum;
 
     if ( @classnum ) {
       push @search, 'COALESCE(cust_main.classnum, 0) IN ('.join(',', @classnum).')';

-----------------------------------------------------------------------

Summary of changes:
 FS/FS/Report/Table.pm     |    1 +
 FS/FS/cust_bill/Search.pm |    2 +-
 2 files changed, 2 insertions(+), 1 deletion(-)




More information about the freeside-commits mailing list