[freeside-commits] freeside/FS/FS/part_event/Action cust_statement.pm, NONE, 1.1 cust_statement_send.pm, NONE, 1.1
Ivan,,,
ivan at wavetail.420.am
Wed Aug 19 21:03:37 PDT 2009
Update of /home/cvs/cvsroot/freeside/FS/FS/part_event/Action
In directory wavetail.420.am:/tmp/cvs-serv8501/FS/FS/part_event/Action
Added Files:
cust_statement.pm cust_statement_send.pm
Log Message:
Emailing statements of accounts, RT#4860
--- NEW FILE: cust_statement.pm ---
package FS::part_event::Action::cust_statement;
use strict;
use base qw( FS::part_event::Action );
use FS::cust_statement;
sub description {
'Group invoices into an informational statement.';
}
sub eventtable_hashref {
{ 'cust_main' => 1, };
{ 'cust_pkg' => 1, };
}
sub default_weight {
90;
}
sub do_action {
my( $self, $cust_main ) = @_;
#my( $self, $object ) = @_;
#my $cust_main = $self->cust_main($object);
my $cust_statement = new FS::cust_statement {
'custnum' => $cust_main->custnum
};
my $error = $cust_statement->insert;
die $error if $error;
'';
}
1;
--- NEW FILE: cust_statement_send.pm ---
package FS::part_event::Action::cust_statement_send;
use strict;
use base qw( FS::part_event::Action );
sub description {
'Send statement (email/print/fax)';
}
sub eventtable_hashref {
{ 'cust_statement' => 1, };
}
sub default_weight {
95;
}
sub do_action {
my( $self, $cust_statement ) = @_;
$cust_statement->send;
}
1;
More information about the freeside-commits
mailing list