[freeside-commits] freeside/FS/FS cust_main.pm, 1.271.2.36, 1.271.2.37

Jeff Finucane,420,, jeff at wavetail.420.am
Fri Dec 21 13:38:14 PST 2007


Update of /home/cvs/cvsroot/freeside/FS/FS
In directory wavetail:/tmp/cvs-serv5142

Modified Files:
      Tag: FREESIDE_1_7_BRANCH
	cust_main.pm 
Log Message:
backport flat, prorate, and subscription plans

Index: cust_main.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/cust_main.pm,v
retrieving revision 1.271.2.36
retrieving revision 1.271.2.37
diff -u -d -r1.271.2.36 -r1.271.2.37
--- cust_main.pm	19 Dec 2007 18:43:00 -0000	1.271.2.36
+++ cust_main.pm	21 Dec 2007 21:38:10 -0000	1.271.2.37
@@ -1983,6 +1983,13 @@
          ( $cust_pkg->getfield('bill') || 0 ) <= $time
     ) {
 
+      # XXX should this be a package event?  probably.  events are called
+      # at collection time at the moment, though...
+      if ( $part_pkg->can('reset_usage') ) {
+        warn "    resetting usage counters" if $DEBUG > 1;
+        $part_pkg->reset_usage($cust_pkg);
+      }
+
       warn "    bill recur\n" if $DEBUG > 1;
 
       # XXX shared with $recur_prog



More information about the freeside-commits mailing list