summaryrefslogtreecommitdiff
path: root/httemplate/search/report_future_autobill.html
diff options
context:
space:
mode:
authorMitch Jackson <mitch@freeside.biz>2018-09-11 05:51:11 -0400
committerMitch Jackson <mitch@freeside.biz>2018-09-11 05:51:11 -0400
commit988d4dcd7e27b38f15edf00ae5b9dd75b9bd0c35 (patch)
treeb9e4d7f973cfb7ba6e5b9da687b32c385abfb891 /httemplate/search/report_future_autobill.html
parentb89e874e8258288d15c98ed3799a9fede6515fd5 (diff)
RT# 78547 Future autobill report - agent virt, dynamic title
Diffstat (limited to 'httemplate/search/report_future_autobill.html')
-rw-r--r--httemplate/search/report_future_autobill.html25
1 files changed, 8 insertions, 17 deletions
diff --git a/httemplate/search/report_future_autobill.html b/httemplate/search/report_future_autobill.html
index ff2f85715..ccde299e9 100644
--- a/httemplate/search/report_future_autobill.html
+++ b/httemplate/search/report_future_autobill.html
@@ -25,6 +25,12 @@ Display date selector for the future_autobill.html report
}
&>
+ <% include('/elements/tr-select-agent.html',
+ 'label' => 'For agent: ',
+ 'disable_empty' => 0,
+ )
+ %>
+
</TABLE>
<BR>
@@ -39,28 +45,13 @@ Display date selector for the future_autobill.html report
<%init>
use FS::cust_payby;
+use FS::CurrentUser;
die "access denied"
unless $FS::CurrentUser::CurrentUser->access_right('Financial reports');
my $target_date = DateTime->now->add(days => 1)->mdy('/');
-
-# Dynamic report title
-my $title_types = '';
-my $card_count = FS::cust_payby->count_autobill_cards;
-my $check_count = FS::cust_payby->count_autobill_checks;
-if ( $card_count && $check_count ) {
- $title_types = 'Card and Check';
-} elsif ( $card_count ) {
- $title_types = 'Card';
-} elsif ( $check_count ) {
- $title_types = 'Check';
-}
-
-my $report_title = sprintf(
- 'Upcoming Auto Bill %s Transactions',
- $title_types,
-);
+my $report_title = FS::cust_payby->future_autobill_report_title;
</%init>