X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2Fpart_event%2FAction%2Fcust_bill_spool_csv.pm;h=0d84e77c47d5f5aefd6d706452a99670472faded;hb=88dbd0c961480b879faa6e8a0556202f41e8202f;hp=250c8304278e78f485043d2130285493d11131b6;hpb=eccc8de2366e2e004a37761b8da2b447ec861ecb;p=freeside.git diff --git a/FS/FS/part_event/Action/cust_bill_spool_csv.pm b/FS/FS/part_event/Action/cust_bill_spool_csv.pm index 250c83042..0d84e77c4 100644 --- a/FS/FS/part_event/Action/cust_bill_spool_csv.pm +++ b/FS/FS/part_event/Action/cust_bill_spool_csv.pm @@ -33,6 +33,10 @@ sub option_fields { empty_label => '(do not upload)', order_by => 'targetnum', }, + 'skip_nopost' => { label => 'Skip customers without postal billing enabled', + type => 'checkbox', + value => 'Y', + }, ); } @@ -44,6 +48,9 @@ sub do_action { #my $cust_main = $self->cust_main($cust_bill); my $cust_main = $cust_bill->cust_main; + return if $self->option('skip_nopost') + && ! grep { $_ eq 'POST' } $cust_main->invoicing_list; + $cust_bill->spool_csv( 'time' => $cust_event->_date, 'format' => $self->option('spoolformat'),