projects
/
freeside.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
b5f5f30
)
just 0-pad the key codes, don't try fancy things with hex and sprintf
author
ivan
<ivan>
Thu, 6 Jan 2005 20:20:24 +0000
(20:20 +0000)
committer
ivan
<ivan>
Thu, 6 Jan 2005 20:20:24 +0000
(20:20 +0000)
FS/FS/cust_svc.pm
patch
|
blob
|
history
FS/FS/part_export/artera_turbo.pm
patch
|
blob
|
history
diff --git
a/FS/FS/cust_svc.pm
b/FS/FS/cust_svc.pm
index
aa0ac5a
..
c91eba1
100644
(file)
--- a/
FS/FS/cust_svc.pm
+++ b/
FS/FS/cust_svc.pm
@@
-316,7
+316,7
@@
sub _svc_label {
my $conf = new FS::Conf;
if ( $conf->config('svc_external-display_type') eq 'artera_turbo' ) {
$tag = sprintf('%010d', $svc_x->id). '-'.
my $conf = new FS::Conf;
if ( $conf->config('svc_external-display_type') eq 'artera_turbo' ) {
$tag = sprintf('%010d', $svc_x->id). '-'.
-
uc( sprintf('%010x', hex($svc_x->title))
);
+
substr('0000000000'.uc($svc_x->title), -10
);
} else {
$tag = $svc_x->id. ': '. $svc_x->title;
}
} else {
$tag = $svc_x->id. ': '. $svc_x->title;
}
diff --git
a/FS/FS/part_export/artera_turbo.pm
b/FS/FS/part_export/artera_turbo.pm
index
2fde0d1
..
bbc6be9
100644
(file)
--- a/
FS/FS/part_export/artera_turbo.pm
+++ b/
FS/FS/part_export/artera_turbo.pm
@@
-104,7
+104,7
@@
sub _export_insert {
if ( $result->{'id'} == 1 ) {
my $new = new FS::svc_external { $svc_external->hash };
$new->id(sprintf('%010d', $result->{'ASN'}));
if ( $result->{'id'} == 1 ) {
my $new = new FS::svc_external { $svc_external->hash };
$new->id(sprintf('%010d', $result->{'ASN'}));
- $new->title(
uc(sprintf('%010x', hex($result->{'AKC'}) ))
);
+ $new->title(
substr('0000000000'.uc($result->{'AKC'}), -10)
);
$new->replace($svc_external);
} else {
$result->{'message'} || 'No response from Artera';
$new->replace($svc_external);
} else {
$result->{'message'} || 'No response from Artera';
@@
-169,7
+169,7
@@
sub statusChange {
my $result = $artera->statusChange(
'asn' => sprintf('%010d', $id),
my $result = $artera->statusChange(
'asn' => sprintf('%010d', $id),
- 'akc' => s
printf('%010x', hex($title)
),
+ 'akc' => s
ubstr("0000000000$title", -10
),
'statusid' => $status,
);
'statusid' => $status,
);