X-Git-Url: http://git.freeside.biz/gitweb/?p=freeside.git;a=blobdiff_plain;f=FS%2Fbin%2Ffreeside-cdr-evariste-import;h=d5e13f98c422f42eba4347e66632b886b980cb83;hp=f61d9d51c3aae3ae2815233fea56dcdcfa949128;hb=bb7e827141c9ed68f30765c9ca2ddcd1d760ad2d;hpb=341f9a85f592a7550fbd48e0b725d8d2fe32c6ac diff --git a/FS/bin/freeside-cdr-evariste-import b/FS/bin/freeside-cdr-evariste-import index f61d9d51c..d5e13f98c 100755 --- a/FS/bin/freeside-cdr-evariste-import +++ b/FS/bin/freeside-cdr-evariste-import @@ -98,14 +98,16 @@ while (my $row = $csth->fetchrow_hashref) { my $cdr = FS::cdr->new ({ # from cdr table 'cdrbatchnum' => $cdr_batch->cdrbatchnum, - 'uniqueid' => $row->{'cdr_id'}, + 'uniqueid' => $row->{'id'}, 'src' => $row->{'src'}, - 'dst' => $row->{'dest'}, - 'startdate' => str2time($row->{'start_time'}), - 'answerdate' => str2time($row->{'answer_time'}), - 'enddate' => str2time($row->{'end_time'}), + 'dst' => $row->{'routing_target'} || $row->{'dest'}, # dest_orig? dest_trans? + 'startdate' => int(str2time($row->{'start_time'})), + 'answerdate' => int(str2time($row->{'answer_time'})), + 'enddate' => int(str2time($row->{'end_time'})), 'duration' => $row->{'duration_sec'}, 'accountcode' => $row->{'customer_id'}, + 'src_ip_addr' => $row->{'src_ip'}, + 'dst_ip_addr' => $row->{'dest_ip'}, # from cdr_rate_postproc table 'billsec' => $row->{'rate_bill_sec'}, 'upstream_price' => $row->{'rate_cost_net'},