[freeside-commits] branch master updated. 2ee09c1343daa939da146c102dbca72f0a98d2bf

Ivan ivan at 420.am
Thu Dec 20 01:51:45 PST 2012


The branch, master has been updated
       via  2ee09c1343daa939da146c102dbca72f0a98d2bf (commit)
       via  578ec27f71498b63102e4cca204575c01c1f8fa9 (commit)
       via  dfe7dc2e2fd943016ce324609d532f5429deb1dd (commit)
      from  a72a10f754f7465121d6137bb3dcee0a21ea6443 (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 2ee09c1343daa939da146c102dbca72f0a98d2bf
Author: Ivan Kohler <ivan at freeside.biz>
Date:   Thu Dec 20 01:51:24 2012 -0800

    add "with email address(es)" and "without postal mail invoices" to adv. customer search, RT#20708

diff --git a/FS/FS/cust_main/Search.pm b/FS/FS/cust_main/Search.pm
index b07223e..1047890 100644
--- a/FS/FS/cust_main/Search.pm
+++ b/FS/FS/cust_main/Search.pm
@@ -633,6 +633,27 @@ sub search {
     if $params->{'with_geocode'};
 
   ##
+  # "with email address(es)" checkbox
+  ##
+
+  push @where,
+    'EXISTS ( SELECT 1 FROM cust_main_invoice
+                WHERE cust_main_invoice.custnum = cust_main.custnum
+                  AND length(dest) > 5
+            )'  # AND dest LIKE '%@%'
+    if $params->{'with_email'};
+
+  ##
+  # "without postal mail invoices" checkbox
+  ##
+
+  push @where,
+    "NOT EXISTS ( SELECT 1 FROM cust_main_invoice
+                    WHERE cust_main_invoice.custnum = cust_main.custnum
+                      AND dest = 'POST' )"
+    if $params->{'no_POST'};
+
+  ##
   # dates
   ##
 
diff --git a/httemplate/search/cust_main.html b/httemplate/search/cust_main.html
index fa79b4d..8b39ea9 100755
--- a/httemplate/search/cust_main.html
+++ b/httemplate/search/cust_main.html
@@ -42,7 +42,8 @@ my %search_hash = ();
 #scalars
 my @scalars = qw (
   agentnum status address zip paydate_year paydate_month invoice_terms
-  no_censustract with_geocode custbatch usernum
+  no_censustract with_geocode with_email no_POST
+  custbatch usernum
   cancelled_pkgs
   cust_fields flattened_pkgs
 );
diff --git a/httemplate/search/report_cust_main.html b/httemplate/search/report_cust_main.html
index 3e7181d..acc49ae 100755
--- a/httemplate/search/report_cust_main.html
+++ b/httemplate/search/report_cust_main.html
@@ -169,6 +169,16 @@
 %   }
 
     <TR>
+      <TD ALIGN="right" VALIGN="center"><% mt('With email address(es)') |h %></TD>
+        <TD><INPUT TYPE="checkbox" NAME="with_email"></TD>
+    </TR>
+
+    <TR>
+      <TD ALIGN="right" VALIGN="center"><% mt('Without postal mail invoices') |h %></TD>
+        <TD><INPUT TYPE="checkbox" NAME="no_POST"></TD>
+    </TR>
+
+    <TR>
       <TH CLASS="background" COLSPAN=2> </TH>
     </TR>
 

commit 578ec27f71498b63102e4cca204575c01c1f8fa9
Author: Ivan Kohler <ivan at freeside.biz>
Date:   Wed Dec 19 23:36:21 2012 -0800

    translate the instructions at least on this page, hanks to Fernando M. Kiernan for the patch

diff --git a/httemplate/pref/pref.html b/httemplate/pref/pref.html
index 575b804..1e9671d 100644
--- a/httemplate/pref/pref.html
+++ b/httemplate/pref/pref.html
@@ -5,7 +5,7 @@
 <% include('/elements/error.html') %>
 
 
-Change password (leave blank for no change)
+<% mt('Change password (leave blank for no change)') |h %>
 <% ntable("#cccccc",2) %>
 
   <TR>

commit dfe7dc2e2fd943016ce324609d532f5429deb1dd
Author: Ivan Kohler <ivan at freeside.biz>
Date:   Wed Dec 19 23:31:49 2012 -0800

    translate 'Adv' in prospect searchbar, thanks to Fernando M. Kiernan for the patch

diff --git a/httemplate/elements/searchbar-prospect.html b/httemplate/elements/searchbar-prospect.html
index ac36379..a604467 100644
--- a/httemplate/elements/searchbar-prospect.html
+++ b/httemplate/elements/searchbar-prospect.html
@@ -2,7 +2,7 @@
 
   <FORM ACTION="<%$fsurl%>search/prospect_main.html" METHOD="GET" STYLE="margin:0">
     <INPUT NAME="search_prospect" TYPE="text" VALUE="<% $prospect_label |n %>" STYLE="width:<%$width%>" onFocus="clearhint_search_prospect(this);" onClick="clearhint_search_prospect(this);" CLASS="fstext"><BR>
-    <A HREF="<%$fsurl%>search/report_prospect_main.html" CLASS="fslink" STYLE="font-size: 11px">Adv</A>
+    <A HREF="<%$fsurl%>search/report_prospect_main.html" CLASS="fslink" STYLE="font-size: 11px"><% mt('Adv') |h %></A>
     <INPUT TYPE="submit" VALUE="Search prospects" CLASS="fsblackbutton" onMouseOver="this.className='fsblackbuttonselected'; return true;" onMouseOut="this.className='fsblackbutton'; return true;" STYLE="font-size:11px;padding-left:1px;padding-right:1px">
   </FORM>
   <% $menu_position eq 'left' ? '<BR>' : '' |n %>

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

Summary of changes:
 FS/FS/cust_main/Search.pm                   |   21 +++++++++++++++++++++
 httemplate/elements/searchbar-prospect.html |    2 +-
 httemplate/pref/pref.html                   |    2 +-
 httemplate/search/cust_main.html            |    3 ++-
 httemplate/search/report_cust_main.html     |   10 ++++++++++
 5 files changed, 35 insertions(+), 3 deletions(-)




More information about the freeside-commits mailing list