summaryrefslogtreecommitdiff
path: root/FS/FS/cdr
diff options
context:
space:
mode:
authorJeremy Davis <jeremyd@freeside.biz>2015-06-01 10:42:33 -0400
committerJeremy Davis <jeremyd@freeside.biz>2015-06-01 10:42:33 -0400
commit588a331885d89bf8eb4f79ab4822e15c0e917329 (patch)
treeae65d6194a5f2d2c3c2690bf044e471efd7ac5e3 /FS/FS/cdr
parent9573631ec3299ced290115ca0cb71690917bb7e2 (diff)
Strip white space from numbers
Diffstat (limited to 'FS/FS/cdr')
-rw-r--r--FS/FS/cdr/ispphone.pm12
1 files changed, 10 insertions, 2 deletions
diff --git a/FS/FS/cdr/ispphone.pm b/FS/FS/cdr/ispphone.pm
index 2817d53..c2ba186 100644
--- a/FS/FS/cdr/ispphone.pm
+++ b/FS/FS/cdr/ispphone.pm
@@ -15,8 +15,16 @@ use Date::Parse;
'import_fields' => [
'accountcode', # Accountcode
- 'src', # Form
- 'dst', # To
+ sub { my ($cdr, $src) = @_;
+ $src =~ s/^\s+//;
+ $cdr->set('src', $src);
+
+ }, # Form
+ sub { my ($cdr, $dst) = @_;
+ $dst =~ s/^\s+//;
+ $cdr->set('dst', $dst);
+
+ }, # To
skip(1), # Country
'upstream_dst_regionname', # Description
_cdr_date_parser_maker('startdate'), #DateTime