[freeside-commits] branch FREESIDE_3_BRANCH updated. 07e65d5203cb6a7b0eef9ea794122b272444dd56

Mark Wells mark at 420.am
Wed Jul 3 12:28:39 PDT 2013


The branch, FREESIDE_3_BRANCH has been updated
       via  07e65d5203cb6a7b0eef9ea794122b272444dd56 (commit)
      from  17e015204a59378ef243e685b5dd849835ee1b4f (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 07e65d5203cb6a7b0eef9ea794122b272444dd56
Author: Mark Wells <mark at freeside.biz>
Date:   Wed Jul 3 12:27:47 2013 -0700

    fix agentnum/refnum criteria in accounting summary, #23660, apparent fallout from #18349?

diff --git a/httemplate/search/customer_accounting_summary.html b/httemplate/search/customer_accounting_summary.html
index b48ff21..c9cfa40 100644
--- a/httemplate/search/customer_accounting_summary.html
+++ b/httemplate/search/customer_accounting_summary.html
@@ -121,10 +121,7 @@ die "access denied"
   unless $FS::CurrentUser::CurrentUser->access_right('Financial reports');
 
 my ($agentnum,$sel_agent);
-if ( $cgi->param('agentnum') eq 'all' ) {
-  $agentnum = 0;
-}
-elsif ( $cgi->param('agentnum') =~ /^(\d+)$/ ) {
+if ( $cgi->param('agentnum') =~ /^(\d+)$/ ) {
   $agentnum = $1;
   $sel_agent = qsearchs('agent', { 'agentnum' => $agentnum } );
   die "agentnum $agentnum not found!" unless $sel_agent;
@@ -177,10 +174,6 @@ my $query = FS::cust_main::Search->search(\%search_hash);
 my @custs = qsearch($query);
 
 foreach my $cust_main ( @custs ) {
-  # XXX should do this in the qsearch
-  next unless ($status eq '' || $status eq $cust_main->status); 
-  next unless ($agentnum == 0 || $cust_main->agentnum eq $agentnum);
-  next unless ($refnum   == 0 || $cust_main->refnum eq $refnum);
 
   push @custnames, $cust_main->name;
 

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

Summary of changes:
 httemplate/search/customer_accounting_summary.html |    9 +--------
 1 files changed, 1 insertions(+), 8 deletions(-)




More information about the freeside-commits mailing list