Fix date format string and quoting of password
authormark <mark>
Sat, 19 Dec 2009 20:58:13 +0000 (20:58 +0000)
committermark <mark>
Sat, 19 Dec 2009 20:58:13 +0000 (20:58 +0000)
FS/FS/pay_batch/paymentech.pm
FS/bin/freeside-paymentech-download
FS/bin/freeside-paymentech-upload

index b75f256..d62a1f1 100644 (file)
@@ -66,7 +66,7 @@ my %paytype = (
     $xml->startTag('transRequest', RequestCount => scalar(@cust_pay_batch) + 1);
     $xml->startTag('batchFileID');
     $xml->dataElement(userID => $username);
-    $xml->dataElement(fileDateTime => time2str('%Y%m%d%H%M%s', time));
+    $xml->dataElement(fileDateTime => time2str('%Y%m%d%H%M%S', time));
     $xml->dataElement(fileID => 'FILEID');
     $xml->endTag('batchFileID');
 
index 293db84..16ac3c2 100755 (executable)
@@ -68,7 +68,7 @@ BATCH: foreach my $filename (@files) {
   }
 
   #unzip file
-  system('unzip', '-P', '$password', '-q',
+  system('unzip', '-P', $password, '-q',
            "$tmpdir/${filename}_resp.zip", '-d', $tmpdir);
   if(! -f "$tmpdir/${filename}_resp.xml") {
     warn "failed to extract ${filename}_resp.xml from ${filename}_resp.zip\n";
index 42bd278..06bef68 100755 (executable)
@@ -63,7 +63,7 @@ foreach my $pay_batch (@batches) {
   print OUT $text;
   close OUT;
 
-  system('zip', '-P', '$password', '-q', '-j',
+  system('zip', '-P', $password, '-q', '-j',
            "$tmpdir/$filename.zip", "$tmpdir/$filename.xml");
 
   die "failed to create zip file\n" if (! -f "$tmpdir/$filename.zip" );