Add CAMTParser (ISO 20022) alongside MT940; accept both formats
- New CAMTParser project: namespace-agnostic parser for camt.052/053/054 producing a statement/entry model aligned with the banking columns (account, amount, debit/credit, dates, counterparty, references, remittance). - BankingService now auto-detects the upload format (XML→CAMT, else MT940) and maps either into the same fds__tt__bankingtransactions DataTable, so the bam/up handler transparently accepts both. - Frontend (fis.bam.de.js) upload field now advertises accept for both MT940 (.sta/.mt940/.txt) and CAMT (.xml/.camt). - Tests (+14, 151 total): CamtParserTests cover parsing (credit/debit, namespace-version agnostic, reversals), detection, and failure/edge inputs (empty, invalid XML, non-CAMT); BankingDualFormatTests verify CAMT and MT940 both land in the same DataTable. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
@@ -36,7 +36,8 @@ let $bcol = {
|
||||
{ name: 'EndToEndReference', label: 'Referenz', type: 'string' }
|
||||
]),
|
||||
bsu: new fields_definition('Kontobericht', 'Kontoberichte', [
|
||||
{ name: 'bsu', label: 'Export der Buchungen', type: 'file', required: true, prop: { multiple: true } }
|
||||
// Accepts both MT940 (SWIFT text: .sta/.mt940/.txt) and CAMT (ISO 20022 XML: .xml/.camt).
|
||||
{ name: 'bsu', label: 'Export der Buchungen (MT940 oder CAMT)', type: 'file', required: true, prop: { multiple: true, accept: '.sta,.mt940,.txt,.xml,.camt,application/xml,text/xml,text/plain' } }
|
||||
])
|
||||
};
|
||||
let gi = (n, c) => $$.sc(`glyphicon glyphicon-${n}`).aC(c);
|
||||
|
||||
Reference in New Issue
Block a user