freeside/FS/FS cust_pkg.pm,1.23.4.17,1.23.4.18

ivan ivan at pouncequick.420.am
Fri Jun 25 01:44:58 PDT 2004


Update of /home/cvs/cvsroot/freeside/FS/FS
In directory pouncequick:/tmp/cvs-serv28430

Modified Files:
      Tag: FREESIDE_1_4_BRANCH
	cust_pkg.pm 
Log Message:
move up next bill date on unsuspend

Index: cust_pkg.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/cust_pkg.pm,v
retrieving revision 1.23.4.17
retrieving revision 1.23.4.18
diff -u -d -r1.23.4.17 -r1.23.4.18
--- cust_pkg.pm	3 Mar 2004 13:44:27 -0000	1.23.4.17
+++ cust_pkg.pm	25 Jun 2004 08:44:56 -0000	1.23.4.18
@@ -462,7 +462,10 @@
 
   unless ( ! $self->getfield('susp') ) {
     my %hash = $self->hash;
+    my $inactive = time - $hash{'susp'};
     $hash{'susp'} = '';
+    $hash{'bill'} = ( $hash{'bill'} || $hash{'setup'} ) + $inactive
+      if $inactive > 0 && ( $hash{'bill'} || $hash{'setup'} );
     my $new = new FS::cust_pkg ( \%hash );
     $error = $new->replace($self);
     if ( $error ) {




More information about the freeside-commits mailing list