[freeside-commits] branch master updated. ec5b34c097718b91d98d90fece500864e50892b9

Christopher Burger burgerc at freeside.biz
Wed Oct 24 07:56:24 PDT 2018


The branch, master has been updated
       via  ec5b34c097718b91d98d90fece500864e50892b9 (commit)
      from  25f16a9668fba4e652372228ca55789ce50e2fa8 (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 ec5b34c097718b91d98d90fece500864e50892b9
Author: Christopher Burger <burgerc at freeside.biz>
Date:   Wed Oct 24 10:55:50 2018 -0400

    RT# 76722 - added option to search on tags not selected in advanced customer report

diff --git a/FS/FS/cust_main/Search.pm b/FS/FS/cust_main/Search.pm
index bfaf6217c..3e77704e6 100644
--- a/FS/FS/cust_main/Search.pm
+++ b/FS/FS/cust_main/Search.pm
@@ -1016,8 +1016,9 @@ sub search {
 
     if ( @tagnums ) {
       if ( $params->{'all_tags'} ) {
+        my $exists = $params->{'all_tags'} eq 'all' ? 'exists' : 'not exists';
         foreach ( @tagnums ) {
-          push @where, 'exists(select 1 from cust_tag where '.
+          push @where, $exists.'(select 1 from cust_tag where '.
                        'cust_tag.custnum = cust_main.custnum and tagnum = '.
                        $_ . ')';
         }
diff --git a/httemplate/search/report_cust_main.html b/httemplate/search/report_cust_main.html
index 0a6726215..da2f1a4e9 100755
--- a/httemplate/search/report_cust_main.html
+++ b/httemplate/search/report_cust_main.html
@@ -102,7 +102,9 @@
           <DIV STYLE="display:inline-block; vertical-align:baseline">
             <INPUT TYPE="radio" NAME="all_tags" VALUE="0" CHECKED> Any of these
             <BR>
-            <INPUT TYPE="radio" NAME="all_tags" VALUE="1"> All of these
+            <INPUT TYPE="radio" NAME="all_tags" VALUE="all"> All of these
+            <BR>
+            <INPUT TYPE="radio" NAME="all_tags" VALUE="none"> None of these
           </DIV>
         </TD>
       </TR>

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

Summary of changes:
 FS/FS/cust_main/Search.pm               | 3 ++-
 httemplate/search/report_cust_main.html | 4 +++-
 2 files changed, 5 insertions(+), 2 deletions(-)




More information about the freeside-commits mailing list