projects
/
freeside.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Ticket #33386 cdrtype support for enswitch
[freeside.git]
/
FS
/
FS
/
cdr
/
Import.pm
diff --git
a/FS/FS/cdr/Import.pm
b/FS/FS/cdr/Import.pm
index
ca6ae93
..
39a7772
100644
(file)
--- a/
FS/FS/cdr/Import.pm
+++ b/
FS/FS/cdr/Import.pm
@@
-34,7
+34,7
@@
CDR importing
=head1 CLASS METHODS
=head1 CLASS METHODS
-=item d
o_cl
i_import
+=item d
b
i_import
=cut
=cut
@@
-81,7
+81,7
@@
sub dbi_import {
# )
#my @cols = values %{ $args{column_map} };
# )
#my @cols = values %{ $args{column_map} };
- my $sql = "SELECT * FROM $table "; # join(',', @cols). " FROM $table ".
+ my $sql = "SELECT
$table.
* FROM $table "; # join(',', @cols). " FROM $table ".
$sql .= 'LEFT JOIN '. $args{status_table}.
" ON ( $table.$pkey = ". $args{status_table}. ".$pkey )"
if $args{status_table};
$sql .= 'LEFT JOIN '. $args{status_table}.
" ON ( $table.$pkey = ". $args{status_table}. ".$pkey )"
if $args{status_table};
@@
-117,8
+117,7
@@
sub dbi_import {
$cdr->cdrtypenum($opt{c}) if $opt{c};
$cdr->cdrtypenum($opt{c}) if $opt{c};
- my $pkey_value = $args{status_table} ? $row->{"$table.$pkey"}
- : $row->{$pkey};
+ my $pkey_value = $row->{$pkey};
#print "$pkey_value\n" if $opt{v};
my $error = $cdr->insert;
#print "$pkey_value\n" if $opt{v};
my $error = $cdr->insert;