[IMP] support MT940 without footer record at end of file

Luxemburg multiline MT940 bank statements contain one statement
and have no footer record.
https://www.multiline.lu/fileadmin/media/downloads/MT940_V2_fr.pdf
This commit adapts the base parser to handle that situation.
This commit is contained in:
Stéphane Bidoul
2014-09-22 17:15:38 +02:00
parent d8a40eccc6
commit e561df32ba

View File

@@ -101,6 +101,12 @@ class MT940(object):
record_line = line
except StopIteration:
pass
if self.current_statement:
if record_line:
self.handle_record(cr, record_line)
record_line = ''
self.statements.append(self.current_statement)
self.current_statement = None
return self.statements
def append_continuation_line(self, cr, line, continuation_line):