diff options
author | Mark Wells <mark@freeside.biz> | 2012-03-08 20:30:02 -0800 |
---|---|---|
committer | Mark Wells <mark@freeside.biz> | 2012-03-08 20:30:02 -0800 |
commit | 984fff08c579ff72f6eb7f658d9373079eafb16a (patch) | |
tree | 7652101bc01162e6d4fea5482767d22309bfb225 /FS/FS/detail_format.pm | |
parent | 440a4fe4f826a59a660d744889b24eb751da675b (diff) |
"simple with accountcode" CDR format, #16348
Diffstat (limited to 'FS/FS/detail_format.pm')
-rw-r--r-- | FS/FS/detail_format.pm | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/FS/FS/detail_format.pm b/FS/FS/detail_format.pm index af97f36..f70acc6 100644 --- a/FS/FS/detail_format.pm +++ b/FS/FS/detail_format.pm @@ -171,11 +171,12 @@ sub single_detail { die "$me error combining ".$self->csv->error_input."\n" if !$status; - my $rated_price = $cdr->rated_price; - $rated_price = 0 if $cdr->freesidestatus eq 'no-charge'; + my $object = $self->{inbound} ? $cdr->cdr_termination(1) : $cdr; + my $price = $object->rated_price if $object; + $price = 0 if $cdr->freesidestatus eq 'no-charge'; FS::cust_bill_pkg_detail->new( { - 'amount' => $rated_price, + 'amount' => $price, 'classnum' => $cdr->rated_classnum, 'duration' => $cdr->rated_seconds, 'regionname' => $cdr->rated_regionname, |