projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
4d6e432
)
fix display of tax section on summary invoices, #37417, from #32223
author
Mark Wells
<mark@freeside.biz>
Wed, 29 Jul 2015 23:32:07 +0000
(16:32 -0700)
committer
Mark Wells
<mark@freeside.biz>
Wed, 29 Jul 2015 23:32:29 +0000
(16:32 -0700)
FS/FS/Template_Mixin.pm
patch
|
blob
|
history
diff --git
a/FS/FS/Template_Mixin.pm
b/FS/FS/Template_Mixin.pm
index
0d7c1f1
..
6d272dd
100644
(file)
--- a/
FS/FS/Template_Mixin.pm
+++ b/
FS/FS/Template_Mixin.pm
@@
-1277,11
+1277,17
@@
sub print_generic {
if ( $multisection ) {
if ( $taxtotal > 0 ) {
if ( $multisection ) {
if ( $taxtotal > 0 ) {
+ # there are taxes, so prepare the section to be displayed.
+ # $taxtotal already includes any line items that were already in the
+ # section (fees, taxes that are charged as packages for some reason).
+ # also set 'summarized' to false so that this isn't a summary-only
+ # section.
$tax_section->{'subtotal'} = $other_money_char.
sprintf('%.2f', $taxtotal);
$tax_section->{'pretotal'} = 'New charges sub-total '.
$total->{'total_amount'};
$tax_section->{'description'} = $self->mt($tax_description);
$tax_section->{'subtotal'} = $other_money_char.
sprintf('%.2f', $taxtotal);
$tax_section->{'pretotal'} = 'New charges sub-total '.
$total->{'total_amount'};
$tax_section->{'description'} = $self->mt($tax_description);
+ $tax_section->{'summarized'} = '';
# append it if it's not already there
if ( !grep $tax_section, @sections ) {
# append it if it's not already there
if ( !grep $tax_section, @sections ) {
@@
-2492,7
+2498,6
@@
sub _items_sections {
foreach my $sectionname (keys %{ $s->{$locationnum} }) {
my $section = {
'subtotal' => $s->{$locationnum}{$sectionname},
foreach my $sectionname (keys %{ $s->{$locationnum} }) {
my $section = {
'subtotal' => $s->{$locationnum}{$sectionname},
- 'post_total' => $post_total,
'sort_weight' => 0,
};
if ( $locationnum ) {
'sort_weight' => 0,
};
if ( $locationnum ) {