[freeside-commits] branch master updated. b1d26754480ee77604521236d9cf9952df2d3e12

Christopher Burger burgerc at freeside.biz
Wed Apr 3 07:09:05 PDT 2019


The branch, master has been updated
       via  b1d26754480ee77604521236d9cf9952df2d3e12 (commit)
      from  08de6e70b0862654801677ca9967e2d0d92ff7a5 (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 b1d26754480ee77604521236d9cf9952df2d3e12
Author: Christopher Burger <burgerc at freeside.biz>
Date:   Wed Apr 3 10:08:11 2019 -0400

    RT# 83090 - updated customer search to allow multiple orderbys

diff --git a/FS/FS/cust_main/Search.pm b/FS/FS/cust_main/Search.pm
index 9cd870b96..7216fe604 100644
--- a/FS/FS/cust_main/Search.pm
+++ b/FS/FS/cust_main/Search.pm
@@ -618,7 +618,7 @@ sub search {
   my $dbh = dbh;
 
   my @where = ();
-  my $orderby;
+  my $orderby = "ORDER BY cust_main.custnum";
 
   # initialize these to prevent warnings
   $params = {
@@ -937,7 +937,7 @@ sub search {
       }
     }
 
-    $orderby ||= "ORDER BY cust_main.$field";
+    $orderby .= ", cust_main.$field";
 
   }
 
@@ -1115,7 +1115,7 @@ sub search {
   # setup queries, subs, etc. for the search
   ##
 
-  $orderby ||= 'ORDER BY custnum';
+  $orderby ||= 'ORDER BY cust_main.custnum';
 
   # here is the agent virtualization
   push @where,

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

Summary of changes:
 FS/FS/cust_main/Search.pm | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)




More information about the freeside-commits mailing list