1 package FS::part_event::Action::fee;
4 use base qw( FS::part_event::Action );
6 sub description { 'Late fee (flat)'; }
10 'charge' => { label=>'Amount', type=>'money', }, # size=>7, },
12 'taxclass' => { label=>'Tax class', type=>'select-taxclass', },
13 'nextbill' => { label=>'Hold late fee until next invoice', type=>'checkbox', value=>'Y' },
17 sub default_weight { 10; }
20 my( $self, $cust_object ) = @_;
22 my $cust_main = $self->cust_main($cust_object);
25 'amount' => $self->option('charge'),
26 'pkg' => $self->option('reason'),
27 'taxclass' => $self->option('taxclass')
30 $charge{'start_date'} = $cust_main->next_bill_date #unless its more than N months away?
31 if $self->option('nextbill');
33 my $error = $cust_main->charge( \%charge );