projects
/
freeside.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
correct display of prepay discount info with non-monthly packages, #15040
[freeside.git]
/
FS
/
FS
/
cust_main
/
Billing.pm
diff --git
a/FS/FS/cust_main/Billing.pm
b/FS/FS/cust_main/Billing.pm
index
dca4ab7
..
eb5bd0b
100644
(file)
--- a/
FS/FS/cust_main/Billing.pm
+++ b/
FS/FS/cust_main/Billing.pm
@@
-253,7
+253,8
@@
charges, etc.
=item freq_override
If set, then override the normal frequency and look for a part_pkg_discount
=item freq_override
If set, then override the normal frequency and look for a part_pkg_discount
-to take at that frequency.
+to take at that frequency. This will exclude any packages that aren't billed
+on a monthly cycle.
=item time
=item time
@@
-846,6
+847,12
@@
sub _make_lines {
my $time = $params{'time'} or die "no time specified";
my (%options) = %{$params{options}};
my $time = $params{'time'} or die "no time specified";
my (%options) = %{$params{options}};
+ if ( $part_pkg->freq ne '1' and ($options{'freq_override'} || 0) > 0 ) {
+ # this should never happen
+ die 'freq_override billing attempted on non-monthly package '.
+ $cust_pkg->pkgnum;
+ }
+
my $dbh = dbh;
my $real_pkgpart = $params{real_pkgpart};
my %hash = $cust_pkg->hash;
my $dbh = dbh;
my $real_pkgpart = $params{real_pkgpart};
my %hash = $cust_pkg->hash;