[freeside-commits] branch FREESIDE_3_BRANCH updated. 42a7f7a7bb35a43c28eb135fdb2f200c786e3e86
Ivan Kohler
ivan at freeside.biz
Fri Jul 26 11:40:00 PDT 2019
The branch, FREESIDE_3_BRANCH has been updated
via 42a7f7a7bb35a43c28eb135fdb2f200c786e3e86 (commit)
from f479f1a024a2749279c82a4e2a54e5ca00755e7b (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit 42a7f7a7bb35a43c28eb135fdb2f200c786e3e86
Author: Ivan Kohler <ivan at freeside.biz>
Date: Fri Jul 26 11:39:57 2019 -0700
fix invoicing prorate packages when bill date is edited manually before first billing, RT#83503
diff --git a/FS/FS/part_pkg/prorate_Mixin.pm b/FS/FS/part_pkg/prorate_Mixin.pm
index af0181a37..2b4b59768 100644
--- a/FS/FS/part_pkg/prorate_Mixin.pm
+++ b/FS/FS/part_pkg/prorate_Mixin.pm
@@ -189,8 +189,7 @@ set, in which case it postpones the next bill to the cutoff day.
=cut
sub prorate_setup {
- my $self = shift;
- my ($cust_pkg, $sdate) = @_;
+ my ($self, $cust_pkg, $time) = @_;
my @cutoff_days = $self->cutoff_day($cust_pkg);
if ( @cutoff_days and $self->option('prorate_defer_bill', 1) ) {
if ( $cust_pkg->setup ) {
@@ -204,11 +203,11 @@ sub prorate_setup {
# For some reason (probably user override), the bill date has been set even
# though the package isn't billing yet. Start billing as though that was the
# start date.
- $$sdate = $cust_pkg->bill;
+ $time = $cust_pkg->bill;
$cust_pkg->setup($cust_pkg->bill);
}
# Now figure the start and end of the period that contains the start date.
- my ($mnow, $mend, $mstart) = $self->_endpoints($sdate, @cutoff_days);
+ my ($mnow, $mend, $mstart) = $self->_endpoints($time, @cutoff_days);
# If today is the cutoff day, set the next bill and setup both to
# midnight today, so that the customer will be billed normally for a
# month starting today.
-----------------------------------------------------------------------
Summary of changes:
FS/FS/part_pkg/prorate_Mixin.pm | 7 +++----
1 file changed, 3 insertions(+), 4 deletions(-)
More information about the freeside-commits
mailing list