import torrus 1.0.9
[freeside.git] / FS / FS / cdr / taqua.pm
index 44e2747..26c0bda 100644 (file)
@@ -40,8 +40,8 @@ use FS::cdr qw(_cdr_date_parser_maker);
     },
 
     #10
-    _cdr_date_parser_maker('startdate'),  #CallArrivalTime
-    _cdr_date_parser_maker('enddate'),    #CallCompletionTime
+    _cdr_date_parser_maker('startdate', 'gmt' => 1),  #CallArrivalTime
+    _cdr_date_parser_maker('enddate', 'gmt' => 1),    #CallCompletionTime
 
     #Disposition
     #sub { my($cdr, $d ) = @_; $cdr->disposition( $disposition{$d}): },
@@ -57,7 +57,7 @@ use FS::cdr qw(_cdr_date_parser_maker);
                                           # 201 => '',
                                           # 203 => '',
 
-    _cdr_date_parser_maker('answerdate'), #DispositionTime
+    _cdr_date_parser_maker('answerdate', 'gmt' => 1), #DispositionTime
     sub { my($cdr, $field) = @_; },       #TCAP
     sub { my($cdr, $field) = @_; },       #OutboundCarrierConnectTime
     sub { my($cdr, $field) = @_; },       #OutboundCarrierDisconnectTime
@@ -94,7 +94,11 @@ use FS::cdr qw(_cdr_date_parser_maker);
           return;
         }
       }
-      '';
+      if ( $cdr->is_tollfree ) {        # thankfully this is already available
+        $cdr->charged_party($cdr->dst); # and this
+      } else {
+        $cdr->charged_party($field);
+      }
     },
 
     sub { my($cdr, $field) = @_; },       #SubscriberNumber