add option to limit automatic unsuspensions to a specific suspension reason type...
[freeside.git] / bin / cdr-ivr.import
index 4af5da0..212482d 100755 (executable)
@@ -45,8 +45,8 @@ FS::cdr::Import->dbi_import(
     #'' => 'CONVERSION_RATE', #
     'lastapp'           => 'MODULE_NAME', #
     'src'               => 'ANI', # 'clid' => 'ANI', #
-    'dst'               => sub { $_[0]->{'DNIS'} =~ /^011/
-                                   ? $_[0]->{'DNIS'}
+    'dst'               => sub { $_[0]->{'COUNTRY_CODE'} !~ /^1/
+                                   ? "011". $_[0]->{'DETAIL'}
                                    : $_[0]->{'DETAIL'};
                                },
     #'' => 'SALES_GROUP', #
@@ -68,6 +68,7 @@ FS::cdr::Import->dbi_import(
     #'' => 'GRACE_PERIOD', # SMALLINT Grace period associated with the call
     #'' => 'ACCOUNT_TYPE', # Account type from ACCOUNT_TYPES table
   },
+  'batch_name' => 'IVR',
 );
 
 1;