X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=FS%2FFS%2Fpart_pkg%2Fprepaid.pm;h=23d340167a2acfb0d46880514cafddc6db274860;hp=4499d0e52723cf3987ce5a1ba3e4bd2044796f5d;hb=467b269c5cacef3e8486e2288f1b0eeec8fea088;hpb=e13421f071b4a7b872e6d40205ca736125cb294d diff --git a/FS/FS/part_pkg/prepaid.pm b/FS/FS/part_pkg/prepaid.pm index 4499d0e52..23d340167 100644 --- a/FS/FS/part_pkg/prepaid.pm +++ b/FS/FS/part_pkg/prepaid.pm @@ -12,6 +12,11 @@ tie %recur_action, 'Tie::IxHash', 'cancel' => 'cancel', ; +tie my %overlimit_action, 'Tie::IxHash', + 'overlimit' => 'Default overlimit processing', + 'cancel' => 'Cancel', +; + %info = ( 'name' => 'Prepaid, flat rate', #'name' => 'Prepaid (no automatic recurring)', #maybe use it here too @@ -27,8 +32,17 @@ tie %recur_action, 'Tie::IxHash', 'type' => 'select', 'select_options' => \%recur_action, }, + %FS::part_pkg::flat::usage_fields, + 'overlimit_action' => { 'name' => 'Action to take upon reaching a usage limit.', + 'type' => 'select', + 'select_options' => \%overlimit_action, + }, + #XXX if you set overlimit_action to 'cancel', should also have the ability + # to select a reason }, - 'fieldorder' => [ 'setup_fee', 'recur_fee', 'recur_action', ], + 'fieldorder' => [ qw( setup_fee recur_fee recur_action ), + @FS::part_pkg::flat::usage_fieldorder, + ], 'weight' => 25, );