[freeside-commits] freeside/FS/FS AccessRight.pm, 1.31, 1.32 Schema.pm, 1.109, 1.110 cust_main.pm, 1.372, 1.373 part_bill_event.pm, 1.28, 1.29
Jeff Finucane,420,,
jeff at wavetail.420.am
Thu Sep 25 20:54:27 PDT 2008
Update of /home/cvs/cvsroot/freeside/FS/FS
In directory wavetail.420.am:/tmp/cvs-serv13053/FS/FS
Modified Files:
AccessRight.pm Schema.pm cust_main.pm part_bill_event.pm
Log Message:
push out event triggered suspensions
Index: part_bill_event.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/part_bill_event.pm,v
retrieving revision 1.28
retrieving revision 1.29
diff -u -d -r1.28 -r1.29
--- part_bill_event.pm 1 Aug 2007 22:24:36 -0000 1.28
+++ part_bill_event.pm 26 Sep 2008 03:54:25 -0000 1.29
@@ -5,6 +5,8 @@
use Carp qw(cluck confess);
use FS::Record qw( dbh qsearch qsearchs );
use FS::Conf;
+use FS::cust_main;
+use FS::cust_bill;
@ISA = qw( FS::Record );
@EXPORT_OK = qw( due_events );
@@ -244,6 +246,9 @@
sort { $a->seconds <=> $b->seconds
|| $a->weight <=> $b->weight
|| $a->eventpart <=> $b->eventpart }
+ grep { ref($record) ne 'FS::cust_bill' || $_->eventcode !~ /honor_dundate/
+ || $event_time > $record->cust_main->dundate
+ }
grep { $_->seconds <= ( $interval )
&& ! qsearch( 'cust_bill_event', {
'invnum' => $record->get($record->dbdef_table->primary_key),
Index: AccessRight.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/AccessRight.pm,v
retrieving revision 1.31
retrieving revision 1.32
diff -u -d -r1.31 -r1.32
--- AccessRight.pm 8 Sep 2008 02:47:22 -0000 1.31
+++ AccessRight.pm 26 Sep 2008 03:54:25 -0000 1.32
@@ -119,6 +119,7 @@
'Unsuspend customer package',
'Cancel customer package immediately',
'Cancel customer package later',
+ 'Delay suspension events',
'Add on-the-fly cancel reason', #NEW
'Add on-the-fly suspend reason', #NEW
'Edit customer package invoice details', #NEW
Index: cust_main.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/cust_main.pm,v
retrieving revision 1.372
retrieving revision 1.373
diff -u -d -r1.372 -r1.373
--- cust_main.pm 25 Sep 2008 23:44:28 -0000 1.372
+++ cust_main.pm 26 Sep 2008 03:54:25 -0000 1.373
@@ -227,6 +227,8 @@
=item spool_cdr - Enable individual CDR spooling, empty or `Y'
+=item dundate - a suggestion to events (see L<FS::part_bill_event">) to delay until this unix timestamp
+
=item squelch_cdr - Discourage individual CDR printing, empty or `Y'
=back
@@ -2976,14 +2978,16 @@
# 3: insert
##
- foreach my $cust_event ( @cust_event ) {
+ unless( $opt{testonly} ) {
+ foreach my $cust_event ( @cust_event ) {
- my $error = $cust_event->insert();
- if ( $error ) {
- $dbh->rollback if $oldAutoCommit;
- return $error;
- }
+ my $error = $cust_event->insert();
+ if ( $error ) {
+ $dbh->rollback if $oldAutoCommit;
+ return $error;
+ }
+ }
}
$dbh->commit or die $dbh->errstr if $oldAutoCommit;
Index: Schema.pm
===================================================================
RCS file: /home/cvs/cvsroot/freeside/FS/FS/Schema.pm,v
retrieving revision 1.109
retrieving revision 1.110
diff -u -d -r1.109 -r1.110
--- Schema.pm 18 Sep 2008 23:17:01 -0000 1.109
+++ Schema.pm 26 Sep 2008 03:54:25 -0000 1.110
@@ -605,6 +605,7 @@
'stateid_state', 'varchar', 'NULL', $char_d, '', '',
'birthdate' , at date_type, '', '',
'signupdate', at date_type, '', '',
+ 'dundate', @date_type, '', '',
'company', 'varchar', 'NULL', $char_d, '', '',
'address1', 'varchar', '', $char_d, '', '',
'address2', 'varchar', 'NULL', $char_d, '', '',
More information about the freeside-commits
mailing list