[freeside-commits] freeside/FS/FS/part_event/Action cust_bill_print_pdf.pm, NONE, 1.1 cust_bill_print.pm, NONE, 1.1

Ivan,,, ivan at wavetail.420.am
Wed Jul 20 11:34:21 PDT 2011


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

Added Files:
	cust_bill_print_pdf.pm cust_bill_print.pm 
Log Message:
per-agent invoice PDF batches, RT#13727

--- NEW FILE: cust_bill_print_pdf.pm ---
package FS::part_event::Action::cust_bill_print_pdf;

use strict;
use base qw( FS::part_event::Action );

sub description { 'Send invoice (spool PDF only)'; }

sub eventtable_hashref {
  { 'cust_bill' => 1 };
}

sub default_weight { 51; }

sub do_action {
  my( $self, $cust_bill ) = @_;

  #my $cust_main = $self->cust_main($cust_bill);
  #my $cust_main = $cust_bill->cust_main;

  my $opt = { $self->options };
  $opt->{'notice_name'} ||= 'Invoice';

  $cust_bill->batch_invoice($opt);
}

1;

--- NEW FILE: cust_bill_print.pm ---
package FS::part_event::Action::cust_bill_print;

use strict;
use base qw( FS::part_event::Action );

sub description { 'Send invoice (print only)'; }

sub eventtable_hashref {
  { 'cust_bill' => 1 };
}

sub default_weight { 51; }

sub do_action {
  my( $self, $cust_bill ) = @_;

  #my $cust_main = $self->cust_main($cust_bill);
  my $cust_main = $cust_bill->cust_main;

  $cust_bill->print;
}

1;



More information about the freeside-commits mailing list