summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--FS/FS/pay_batch/td_eft1464.pm7
1 files changed, 6 insertions, 1 deletions
diff --git a/FS/FS/pay_batch/td_eft1464.pm b/FS/FS/pay_batch/td_eft1464.pm
index 609a728..e16b0ee 100644
--- a/FS/FS/pay_batch/td_eft1464.pm
+++ b/FS/FS/pay_batch/td_eft1464.pm
@@ -108,8 +108,13 @@ $name = 'td_eft1464';
$i++;
# The 1464 byte format supports up to 5 payments per line,
# but we're only going to send 1.
+
+ ## set to D for debit by default, then override to what cust_pay_batch has as payments may not have paycode.
+ my $debitorcredit = 'D';
+ $debitorcredit = $cust_pay_batch->paycode unless !$cust_pay_batch->paycode;
+
my $control = join('',
- 'D', # for 'debit'
+ $debitorcredit, # D for 'debit' or C for Credit
sprintf("%09u", $i), #record number
$opt{'origid'},
$opt{'fcn'},