diff --git a/ach/builder.py b/ach/builder.py index 1a3c70f..89e17ac 100644 --- a/ach/builder.py +++ b/ach/builder.py @@ -94,6 +94,9 @@ def add_batch(self, std_ent_cls_code, batch_entries=None, entry.trace_num = self.settings['immediate_dest'][:8] \ + entry.validate_numeric_field(entry_counter, 7) + if 'id_number' in record: + entry.id_number = record['id_number'][:15] + entries.append((entry, record.get('addenda', []))) entry_counter += 1 diff --git a/tests/test_line_endings.py b/tests/test_line_endings.py index 6c8d075..facd029 100644 --- a/tests/test_line_endings.py +++ b/tests/test_line_endings.py @@ -41,6 +41,7 @@ def setup(self): 'account_number' : '123123123', 'amount' : '12.13', 'name' : 'Rachel Welch', + 'id_number' : '3333', }, ]