X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2Fpart_pkg%2Fflat.pm;h=84599ea8ade19a23467ba1ee6a8cc97d71b6304a;hb=54eead497d6a8acea3ad8575d194fe027672dbf1;hp=7b5a3f6bbabf3e3386882d7c02173b2b03a2e465;hpb=747fc5e700ae36409be707b202c574a9b15d4c70;p=freeside.git diff --git a/FS/FS/part_pkg/flat.pm b/FS/FS/part_pkg/flat.pm index 7b5a3f6bb..84599ea8a 100644 --- a/FS/FS/part_pkg/flat.pm +++ b/FS/FS/part_pkg/flat.pm @@ -58,8 +58,9 @@ tie my %contract_years, 'Tie::IxHash', ( }, 'prorate_round_day' => { 'name' => 'When synchronizing, round the prorated '. - 'period to the nearest full day', - 'type' => 'checkbox', + 'period', + 'type' => 'select', + 'select_options' => \%FS::part_pkg::prorate_Mixin::prorate_round_day_opts, }, 'add_full_period' => { 'disabled' => 1 }, # doesn't make sense with sync? @@ -174,7 +175,7 @@ sub cutoff_day { my $cust_pkg = shift; if ( $self->option('sync_bill_date',1) ) { my $next_bill = $cust_pkg->cust_main->next_bill_date; - if ( defined($next_bill) ) { + if ( $next_bill ) { # careful here. if the prorate calculation is going to round to # the nearest day, this needs to always return the same result if ( $self->option('prorate_round_day', 1) ) {