projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
1348665
)
fix displaying usage separate from recurring when using separate_usage and invoice_se...
author
ivan
<ivan>
Wed, 3 Aug 2011 22:13:06 +0000
(22:13 +0000)
committer
ivan
<ivan>
Wed, 3 Aug 2011 22:13:06 +0000
(22:13 +0000)
FS/FS/cust_bill_pkg.pm
patch
|
blob
|
history
diff --git
a/FS/FS/cust_bill_pkg.pm
b/FS/FS/cust_bill_pkg.pm
index
59eb4dd
..
c9b0a4d
100644
(file)
--- a/
FS/FS/cust_bill_pkg.pm
+++ b/
FS/FS/cust_bill_pkg.pm
@@
-682,17
+682,17
@@
sub set_display {
|| $cust_pkg->part_pkg->option('usage_mandate', 'Hush!');
# or use the category from $opt{'part_pkg'} if its not bundled?
|| $cust_pkg->part_pkg->option('usage_mandate', 'Hush!');
# or use the category from $opt{'part_pkg'} if its not bundled?
- my $
section
= $cust_pkg->part_pkg->categoryname;
+ my $
categoryname
= $cust_pkg->part_pkg->categoryname;
return $self->set('display', [])
return $self->set('display', [])
- unless $separate || $
section
|| $usage_mandate;
+ unless $separate || $
categoryname
|| $usage_mandate;
my @display = ();
my @display = ();
- my %hash = ( 'section' => $
section
);
+ my %hash = ( 'section' => $
categoryname
);
-
$
section = $part_pkg->option('usage_section', 'Hush!')
- || $cust_pkg->part_pkg->option('usage_section', 'Hush!');
+
my $usage_
section = $part_pkg->option('usage_section', 'Hush!')
+
|| $cust_pkg->part_pkg->option('usage_section', 'Hush!');
my $summary = $part_pkg->option('summarize_usage', 'Hush!')
|| $cust_pkg->part_pkg->option('summarize_usage', 'Hush!');
my $summary = $part_pkg->option('summarize_usage', 'Hush!')
|| $cust_pkg->part_pkg->option('summarize_usage', 'Hush!');
@@
-708,18
+708,18
@@
sub set_display {
};
}
};
}
- if ($separate && $section && $summary) {
+ if ($separate && $
usage_
section && $summary) {
push @display, new FS::cust_bill_pkg_display { type => 'U',
summary => 'Y',
%hash,
};
}
push @display, new FS::cust_bill_pkg_display { type => 'U',
summary => 'Y',
%hash,
};
}
- if ($usage_mandate ||
$section && $summary
) {
+ if ($usage_mandate ||
($usage_section && $summary)
) {
$hash{post_total} = 'Y';
}
if ($separate || $usage_mandate) {
$hash{post_total} = 'Y';
}
if ($separate || $usage_mandate) {
- $hash{section} = $
section if ($separate || $usage_mandate)
;
+ $hash{section} = $
usage_section if $usage_section
;
push @display, new FS::cust_bill_pkg_display { type => 'U', %hash };
}
push @display, new FS::cust_bill_pkg_display { type => 'U', %hash };
}