projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
7881e58
)
fix display of zero-amount line items in some cases, #30821
author
Mark Wells
<mark@freeside.biz>
Sat, 4 Oct 2014 00:21:53 +0000
(17:21 -0700)
committer
Mark Wells
<mark@freeside.biz>
Sat, 4 Oct 2014 00:21:53 +0000
(17:21 -0700)
FS/FS/Template_Mixin.pm
patch
|
blob
|
history
diff --git
a/FS/FS/Template_Mixin.pm
b/FS/FS/Template_Mixin.pm
index
06b3d9e
..
d652d53
100644
(file)
--- a/
FS/FS/Template_Mixin.pm
+++ b/
FS/FS/Template_Mixin.pm
@@
-2031,27
+2031,20
@@
sub _items_sections {
! $cust_bill_pkg->feepart and
! $section;
! $cust_bill_pkg->feepart and
! $section;
- if (
! $type || $type eq 'S'
) {
+ if (
$type eq 'S'
) {
$subtotal{$locationnum}{$section} += $cust_bill_pkg->setup
if $cust_bill_pkg->setup != 0
|| $cust_bill_pkg->setup_show_zero;
$subtotal{$locationnum}{$section} += $cust_bill_pkg->setup
if $cust_bill_pkg->setup != 0
|| $cust_bill_pkg->setup_show_zero;
- }
-
- if (! $type) {
- $subtotal{$locationnum}{$section} += $cust_bill_pkg->recur
- if $cust_bill_pkg->recur != 0
- || $cust_bill_pkg->recur_show_zero;
- }
-
- if ($type && $type eq 'R') {
+ } elsif ( $type eq 'R' ) {
$subtotal{$locationnum}{$section} += $cust_bill_pkg->recur - $usage
if $cust_bill_pkg->recur != 0
|| $cust_bill_pkg->recur_show_zero;
$subtotal{$locationnum}{$section} += $cust_bill_pkg->recur - $usage
if $cust_bill_pkg->recur != 0
|| $cust_bill_pkg->recur_show_zero;
- }
-
- if ($type && $type eq 'U') {
+ } elsif ( $type eq 'U' ) {
$subtotal{$locationnum}{$section} += $usage
unless scalar(@extra_sections);
$subtotal{$locationnum}{$section} += $usage
unless scalar(@extra_sections);
+ } elsif ( !$type ) {
+ $subtotal{$locationnum}{$section} += $cust_bill_pkg->setup
+ + $cust_bill_pkg->recur;
}
}
}
}