db00db771c25d54975936aa9cd003ab61f8ff2dc
[freeside.git] / FS / FS / cdr / cisco.pm
1 package FS::cdr::cisco;
2
3 use strict;
4 use base qw( FS::cdr );
5 use vars qw( %info );
6 use FS::cdr qw( _cdr_date_parser_maker _cdr_min_parser_maker );
7
8 %info = (
9   'name'          => 'Cisco Unified Call Manager',
10   'weight'        => 160,
11   'header'        => 2,     #0 default, set to 1 to ignore the first line, or
12                             # to higher numbers to ignore that number of lines
13   'type'          => 'csv', #csv (default), fixedlength or xls
14   'sep_char'      => ',',   #for csv, defaults to ,
15   'disabled'      => 0,     #0 default, set to 1 to disable
16
17   'import_fields' => [
18
19                                              skip(2),   #cdrRecordType
20                                                         #globalCallID_callManagerId
21                                               'clid',   #globalCallID_callId    
22                                              skip(1),   #origLegCallIdentifier  
23                                          'calldate',    #dateTimeOrigination
24                                              skip(3),   #origNodeId     
25                                                         #origSpan
26                                                         #origIpAddr     
27                                                'src',   #callingPartyNumber     
28                                             skip(20),   #callingPartyUnicodeLoginUserID 
29                                                         #origCause_location     
30                                                         #origCause_value        
31                                                         #origPrecedenceLevel    
32                                                         #origMediaTransportAddress_IP   
33                                                         #origMediaTransportAddress_Port 
34                                                         #origMediaCap_payloadCapability
35                                                         #origMediaCap_maxFramesPerPacket
36                                                         #origMediaCap_g723BitRate       
37                                                         #origVideoCap_Codec     
38                                                         #origVideoCap_Bandwidth 
39                                                         #origVideoCap_Resolution        
40                                                         #origVideoTransportAddress_IP   
41                                                         #origVideoTransportAddress_Port 
42                                                         #origRSVPAudioStat      
43                                                         #origRSVPVideoStat      
44                                                         #destLegIdentifier      
45                                                         #destNodeId     
46                                                         #destSpan       
47                                                         #destIpAddr     
48                                               'dst',    #originalCalledPartyNumber      
49                                            skip(17),    #finalCalledPartyNumber 
50                                                         #finalCalledPartyUnicodeLoginUserID
51                                                         #destCause_location     
52                                                         #destCause_value
53                                                         #destPrecedenceLevel
54                                                         #destMediaTransportAddress_IP
55                                                         #destMediaTransportAddress_Port 
56                                                         #destMediaCap_payloadCapability 
57                                                         #destMediaCap_maxFramesPerPacket
58                                                         #destMediaCap_g723BitRate
59                                                         #destVideoCap_Codec
60                                                         #destVideoCap_Bandwidth
61                                                         #destVideoCap_Resolution
62                                                         #destVideoTransportAddress_IP
63                                                         #destVideoTransportAddress_Port
64                                                         #destRSVPAudioStat
65                                                         #destRSVPVideoStat
66                                         'answerdate',   #dateTimeConnect        
67                                            'enddate',   #dateTimeDisconnect
68                                         skip(6),        #lastRedirectDn 
69                                                         #pkid
70                                                         #originalCalledPartyNumberPartition     
71                                                         #callingPartyNumberPartition    
72                                                         #finalCalledPartyNumberPartition
73                                                         #lastRedirectDnPartition
74                                        'billsec',       #duration
75                                         skip(48),       #origDeviceName
76                                                         #destDeviceName
77                                                         #origCallTerminationOnBehalfOf
78                                                         #destCallTerminationOnBehalfOf
79                                                         #origCalledPartyRedirectOnBehalfOf
80                                                         #lastRedirectRedirectOnBehalfOf 
81                                                         #origCalledPartyRedirectReason
82                                                         #lastRedirectRedirectReason
83                                                         #destConversationId
84                                                         #globalCallId_ClusterID
85                                                         #joinOnBehalfOf
86                                                         #comment        
87                                                         #authCodeDescription
88                                                         #authorizationLevel     
89                                                         #clientMatterCode
90                                                         #origDTMFMethod
91                                                         #destDTMFMethod 
92                                                         #callSecuredStatus
93                                                         #origConversationId
94                                                         #origMediaCap_Bandwidth
95                                                         #destMediaCap_Bandwidth 
96                                                         #authorizationCodeValue
97                                                         #outpulsedCallingPartyNumber
98                                                         #outpulsedCalledPartyNumber
99                                                         #origIpv4v6Addr 
100                                                         #destIpv4v6Addr 
101                                                         #origVideoCap_Codec_Channel2
102                                                         #origVideoCap_Bandwidth_Channel2
103                                                         #origVideoCap_Resolution_Channel2
104                                                         #origVideoTransportAddress_IP_Channel2  
105                                                         #origVideoTransportAddress_Port_Channel2
106                                                         #origVideoChannel_Role_Channel2
107                                                         #destVideoCap_Codec_Channel2
108                                                         #destVideoCap_Bandwidth_Channel2
109                                                         #destVideoCap_Resolution_Channel2
110                                                         #destVideoTransportAddress_IP_Channel2
111                                                         #destVideoTransportAddress_Port_Channel2
112                                                         #destVideoChannel_Role_Channel2
113                                                         #IncomingProtocolID
114                                                         #IncomingProtocolCallRef
115                                                         #OutgoingProtocolID
116                                                         #OutgoingProtocolCallRef        
117                                                         #currentRoutingReason
118                                                         #origRoutingReason
119                                                         #lastRedirectingRoutingReason
120                                                         #huntPilotPartition
121                                                         #huntPilotDN
122                                                         #calledPartyPatternUsage
123   ],
124
125 );
126
127
128
129
130 sub skip { map {''} (1..$_[0]) }
131
132 1;
133