[freeside-commits] branch FREESIDE_3_BRANCH updated. 9527575801494bc501c555928e4bf922049b0abe

Mark Wells mark at 420.am
Tue Oct 27 16:47:20 PDT 2015


The branch, FREESIDE_3_BRANCH has been updated
       via  9527575801494bc501c555928e4bf922049b0abe (commit)
      from  59dabb780e7fa25290392bb3c40d3f87b404463d (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 9527575801494bc501c555928e4bf922049b0abe
Author: Mark Wells <mark at freeside.biz>
Date:   Tue Oct 27 16:28:32 2015 -0700

    fix interaction of percentage discount and quantity, #19354, etc.

diff --git a/FS/FS/part_pkg/discount_Mixin.pm b/FS/FS/part_pkg/discount_Mixin.pm
index 5de7d8e..ecbab09 100644
--- a/FS/FS/part_pkg/discount_Mixin.pm
+++ b/FS/FS/part_pkg/discount_Mixin.pm
@@ -141,7 +141,7 @@ sub calc_discount {
       # XXX it would be more accurate for calc_recur to just _tell us_ what
       # it's going to charge
 
-      my $recur_charge = $br * ($cust_pkg->quantity || 1) * $chg_months / $self->freq;
+      my $recur_charge = $br * $chg_months / $self->freq;
       # round this, because the real recur charge is rounded
       $recur_charge = sprintf('%.2f', $recur_charge);
 

-----------------------------------------------------------------------

Summary of changes:
 FS/FS/part_pkg/discount_Mixin.pm |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)




More information about the freeside-commits mailing list