[freeside-commits] freeside/FS/FS discount_plan.pm,1.1,1.2

Ivan,,, ivan at wavetail.420.am
Tue Dec 20 15:50:21 PST 2011


Update of /home/cvs/cvsroot/freeside/FS/FS
In directory wavetail.420.am:/tmp/cvs-serv10339

Modified Files:
	discount_plan.pm 
Log Message:
fix 'Can't call method "setup" on an undefined value' error when using into rates together with term discounts, RT#15661

Index: discount_plan.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/discount_plan.pm,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -w -d -r1.1 -r1.2
--- discount_plan.pm	7 Dec 2011 05:50:32 -0000	1.1
+++ discount_plan.pm	20 Dec 2011 23:50:19 -0000	1.2
@@ -63,7 +63,7 @@
     my $recur = $cust_bill_pkg->recur || 0;
 
     if ( $freq eq '1' ) { # monthly recurring package
-      my $permonth = $part_pkg->base_recur_permonth || 0;
+      my $permonth = $part_pkg->base_recur_permonth($cust_pkg) || 0;
 
       my ($discount) = grep { $_->months == $months }
       map { $_->discount } $part_pkg->part_pkg_discount;



More information about the freeside-commits mailing list