enable CardFortress in test database, #71513
[freeside.git] / bin / cust_pay_histogram
index d43a4d1..42bd884 100755 (executable)
@@ -34,7 +34,9 @@ my @payrow = qsearch( { table     => 'cust_pay',
                     );
 
 my $max = 0;
+my $sum = 0;
 foreach (@payrow) {
+  $sum += $_->quantity;
   $max = $_->quantity if $_->quantity > $max;
 }
 my $scale = int($max/60) + 1;
@@ -45,6 +47,7 @@ print " UNTIL $opt{e}" if $opt{e};
 print " VIA $opt{p}" if $opt{p};
 print " BY AGENT $opt{a}" if $opt{a};
 print "\n\n";
+print "Total number of payments: $sum\n\n";
 print "(each * represents $scale)\n\n" if $scale > 1;
 
 foreach my $payrow ( @payrow ) {
@@ -100,7 +103,7 @@ Displays a histogram of cust_pay records in the database.
 
   -a: Only process payments of customers with the specified agentnum
 
-user: From the mapsecrets file - see config.html from the base documentation
+user: Freeside username
 
 =head1 BUGS