diff options
Diffstat (limited to 'httemplate/view/cust_main/menu.html')
| -rw-r--r-- | httemplate/view/cust_main/menu.html | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/httemplate/view/cust_main/menu.html b/httemplate/view/cust_main/menu.html index e85cc2529..ff8937a8f 100644 --- a/httemplate/view/cust_main/menu.html +++ b/httemplate/view/cust_main/menu.html @@ -112,6 +112,9 @@ my $conf = FS::Conf->new; my %payby = map { $_ => 1 } $conf->config('payby'); +# cached for conditions, to avoid looking it up twice +my $invoicing_list_emailonly = $cust_main->invoicing_list_emailonly; + # nice declarative menu; should be a parameter to some kind of menu generator my @menu = ( [ @@ -197,7 +200,8 @@ my @menu = ( 'misc/email-customers.html?table=cust_main;search_hash='. 'agent_virt_agentnum='.$agentnum.";custnum=$custnum"; }, - condition => sub { shift->invoicing_list_emailonly }, + condition => sub { $invoicing_list_emailonly }, + acl => 'Bulk send customer notices', }, ], [ @@ -478,6 +482,18 @@ my @menu = ( FS::cust_pay_pending->count('custnum = ?', shift->custnum) > 0 }, }, + { + label => 'Email payment history to this customer', + url => sub { + my $cust_main = shift; + my $agentnum = $cust_main->agentnum; + 'misc/email-customers-history.html?table=cust_main;search_hash='. + 'agent_virt_agentnum='.$agentnum.";custnum=$custnum;url=". + uri_escape($cgi->self_url); + }, + condition => sub { $invoicing_list_emailonly }, + acl => 'Bulk send customer notices', + }, ], [ { |
