X-Git-Url: http://git.freeside.biz/gitweb/?a=blobdiff_plain;f=FS%2FFS%2Fpart_pkg%2Fvoip_cdr.pm;h=71a82aa1179bdd556d0449f63a61413831da528d;hb=4f3925e2d4db8181b70e9c04bf95f31760a8f7e2;hp=41c0888d35d8d16ec82fdd297f2cf82e14be1b72;hpb=0fb7ffd120c41dabfc34b6c06443a7604d879f8a;p=freeside.git diff --git a/FS/FS/part_pkg/voip_cdr.pm b/FS/FS/part_pkg/voip_cdr.pm index 41c0888d3..71a82aa11 100644 --- a/FS/FS/part_pkg/voip_cdr.pm +++ b/FS/FS/part_pkg/voip_cdr.pm @@ -17,7 +17,7 @@ use List::Util qw(first min); @ISA = qw(FS::part_pkg::recur_Common); -$DEBUG = 1; +$DEBUG = 0; tie my %cdr_svc_method, 'Tie::IxHash', 'svc_phone.phonenum' => 'Phone numbers (svc_phone.phonenum)', @@ -95,6 +95,10 @@ tie my %granularity, 'Tie::IxHash', FS::rate_detail::granularities(); 'select_label' => 'ratename', }, + 'min_included' => { 'name' => 'Minutes included when using "single price per minute" rating method', + }, + + 'min_charge' => { 'name' => 'Charge per minute when using "single price per minute" rating method', }, @@ -185,7 +189,7 @@ tie my %granularity, 'Tie::IxHash', FS::rate_detail::granularities(); 'skip_lastapp' => { 'name' => 'Do not charge for CDRs where the lastapp matches this value: ', }, - 'skip_max_callers' => { 'name' => 'Do not charge for CDRs where max_callers is greater than this value: ', + 'skip_max_callers' => { 'name' => 'Do not charge for CDRs where max_callers is less than or equal to this value: ', }, 'use_duration' => { 'name' => 'Calculate usage based on the duration field instead of the billsec field', @@ -908,10 +912,10 @@ sub check_chargable { } - return "max_callers > $opt{skip_max_callers}" + return "max_callers <= $opt{skip_max_callers}" if length($opt{'skip_max_callers'}) and length($cdr->max_callers) - and $cdr->max_callers > $opt{'skip_max_callers'}; + and $cdr->max_callers <= $opt{'skip_max_callers'}; #all right then, rate it '';