summaryrefslogtreecommitdiff
path: root/FS
diff options
context:
space:
mode:
authorivan <ivan>2009-11-14 00:08:13 +0000
committerivan <ivan>2009-11-14 00:08:13 +0000
commit0ea039f9084014e27a1b99ff033bf04bdab94966 (patch)
tree6582fbcb2e6461d8c659488911e6776f58c529e3 /FS
parent44d4252de771e6d41749363a61033452f1e97a15 (diff)
add invoice terms to advanced customer report. dogfood.
Diffstat (limited to 'FS')
-rw-r--r--FS/FS/cust_main.pm16
1 files changed, 16 insertions, 0 deletions
diff --git a/FS/FS/cust_main.pm b/FS/FS/cust_main.pm
index 858ac14ff..08c7a5113 100644
--- a/FS/FS/cust_main.pm
+++ b/FS/FS/cust_main.pm
@@ -8405,6 +8405,22 @@ sub search_sql {
;
}
+ ###
+ # invoice terms
+ ###
+
+ if ( $params->{'invoice_terms'} =~ /^([\w ]+)$/ ) {
+ my $terms = $1;
+ if ( $1 eq 'NULL' ) {
+ push @where,
+ "( cust_main.invoice_terms IS NULL OR cust_main.invoice_terms = '' )";
+ } else {
+ push @where,
+ "cust_main.invoice_terms IS NOT NULL",
+ "cust_main.invoice_terms = '$1'";
+ }
+ }
+
##
# amounts
##