This commit was generated by cvs2svn to compensate for changes in r11022,
[freeside.git] / FS / FS / cdr / enswitch.pm
1 package FS::cdr::enswitch;
2
3 use strict;
4 use vars qw( @ISA %info $tmp_mon $tmp_mday $tmp_year );
5 use Time::Local;
6 use FS::cdr qw(_cdr_min_parser_maker);
7
8 @ISA = qw(FS::cdr);
9
10 %info = (
11   'name'          => 'Enswitch',
12   'weight'        => 515,
13   'header'        => 2,
14   'type'          => 'csv',
15   'import_fields' => [
16     'disposition',  #Status
17     'startdate',    #Start, already a unix timestamp
18     skip(2),        #Start date, Start time
19     'enddate',      #End
20     skip(4),        #End date, End time
21                     #Calling customer, Calling type
22     'src',          #Calling number
23     'clid',         #Calling name
24     skip(1),        #Called type
25     'dst',          #Called number
26     skip(23),       #Destination customer, Destination type
27                     #Destination number
28                     #Destination group ID, Destination group name,
29                     #Inbound calling type, Inbound calling number,
30                     #Inbound called type, Inbound called number,
31                     #Inbound destination type, Inbound destination number,
32                     #Outbound calling type, Outbound calling number,
33                     #Outbound called type, Outbound called number,
34                     #Outbound destination type, Outbound destination number,
35                     #Internal calling type, Internal calling number,
36                     #Internal called type, Internal called number,
37                     #Internal destination type, Internal destination number
38     'duration',     #Total seconds
39     skip(1),        #Ring seconds
40     'billsec',      #Billable seconds
41     'upstream_price', #Cost
42     'accountcode',  #Billing customer
43     skip(3),        #Billing customer name, Billing type, Billing reference
44   ],
45 );
46
47 sub skip { map {''} (1..$_[0]) }
48
49 1;