X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=httemplate%2Fview%2Fcust_main%2Fbilling.html;h=8d3925a08220df59199bc2e645979de014df13c8;hb=ea63022518b3fb7360e64aa2bb1bb0d9d56ce9d4;hp=c031ce929a83b3386a4841894bbd825e1eb2fb26;hpb=31d3be5e80b4c92367dc84fea9f8bf3ee2d14480;p=freeside.git diff --git a/httemplate/view/cust_main/billing.html b/httemplate/view/cust_main/billing.html index c031ce929..8d3925a08 100644 --- a/httemplate/view/cust_main/billing.html +++ b/httemplate/view/cust_main/billing.html @@ -1,6 +1,8 @@ <% mt('Billing information') |h %> % my $yes = emt('yes'); % my $no = emt('no'); +% my $allowed = emt('allowed'); +% my $refused = emt('refused');
<% $balance %> | -% #54: just an arbitrary number i pulled out of my goober. ideally we'd like -% # to consider e.g. a histogram of num_ncancelled_packages for the entire -% # customer base, and compare it to a graph of the overhead for generating this -% # information. (and optimize it better, we could get it more from SQL) -% if ( $cust_main->num_ncancelled_pkgs < 54 ) { -% my $sth = dbh->prepare(" -% SELECT DISTINCT freq FROM cust_pkg LEFT JOIN part_pkg USING (pkgpart) -% WHERE freq IS NOT NULL AND freq != '0' -% AND ( cancel IS NULL OR cancel = 0 ) -% AND custnum = ? -% ") or die $DBI::errstr; -% -% $sth->execute($cust_main->custnum) or die $sth->errstr; +||||
<% emt( 'Recurring' ) %> | ++ | |||
---|---|---|---|---|
<% emt( ucfirst($freq_pretty). ' recurring' ) %> | -<% $money_char. sprintf('%.2f', $amount) %> | - -|||
<% mt('Prorate day of month') |h %> | <% $cust_main->prorate_day %> + <% $cust_main->force_prorate_day && (''.emt('(applies to all packages)').'') %> | |||
<% mt('Postal mail invoices') |h %> | -- <% ( grep { $_ eq 'POST' } @invoicing_list ) - ? $yes. ( $cust_main->invoice_attn +% if ( $cust_main->postal_invoice ) { + | <% $yes . ( $cust_main->invoice_attn ? ', attn: '. $cust_main->invoice_attn : '' - ) - : $no - %> + ) %> + | +% } elsif ( $cust_main->invoice_noemail +% or scalar(@invoicing_list) == 0 ) { +% # alert the user that this customer has no way to receive an invoice +<% $no %> | +% } else { +<% $no %> | +% }
<% mt('Email invoices') |h %> | -- <% $cust_main->invoice_noemail ? $no : $yes %> - | +% if ( $cust_main->invoice_noemail and ! $cust_main->postal_invoice ) { +% # as above, warn if the customer refuses both email and postal invoices +<% $refused %> | +% } else { +<% $cust_main->invoice_noemail ? $refused : $allowed %> | +% }|
<% mt('Email address(es)') |h %> | +<% mt('Other email notices') |h %> |
- <% join(', ', grep { $_ !~ /^(POST|FAX)$/ } @invoicing_list ) || $no %>
-% if ( $cust_main->message_noemail ) {
- - <% emt('(do not send notices)') %> -% } + <% $cust_main->message_noemail ? $refused : $allowed %> |
||
<% mt('Invoice terms') |h %> | @@ -227,9 +221,9 @@ | |||
<% mt('Email CDRs as CSV') |h %> | +<% mt('Email CDRs as '.uc($attach)) |h %> | <% $cust_main->email_csv_cdr ? $yes : $no %> |