Browse Source

[FIX] Updated headers, README.rst's and removed vim lines.

pull/15/head
Ronald Portier (Therp BV) 10 years ago
parent
commit
23eaa765d9
  1. 40
      account_bank_statement_import/account_bank_statement_import.py
  2. 49
      bank_statement_parse/README.rst
  3. 4
      bank_statement_parse/__openerp__.py
  4. 5
      bank_statement_parse/parserlib.py
  5. 46
      bank_statement_parse_camt/README.rst
  6. 8
      bank_statement_parse_camt/__openerp__.py
  7. 5
      bank_statement_parse_camt/account_bank_statement_import.py
  8. 3
      bank_statement_parse_camt/camt.py
  9. 2
      bank_statement_parse_camt/tests/__init__.py
  10. 4
      bank_statement_parse_camt/tests/test_import_bank_statement.py
  11. 53
      bank_statement_parse_mt940/README.rst
  12. 14
      bank_statement_parse_mt940/__openerp__.py
  13. 5
      bank_statement_parse_mt940/mt940.py
  14. 50
      bank_statement_parse_nl_ing_mt940/README.rst
  15. 8
      bank_statement_parse_nl_ing_mt940/__openerp__.py
  16. 7
      bank_statement_parse_nl_ing_mt940/account_bank_statement_import.py
  17. 3
      bank_statement_parse_nl_ing_mt940/mt940.py
  18. 4
      bank_statement_parse_nl_ing_mt940/tests/test_import_bank_statement.py
  19. 47
      bank_statement_parse_nl_rabo_mt940/README.rst
  20. 10
      bank_statement_parse_nl_rabo_mt940/__openerp__.py
  21. 5
      bank_statement_parse_nl_rabo_mt940/account_bank_statement_import.py
  22. 2
      bank_statement_parse_nl_rabo_mt940/mt940.py
  23. 2
      bank_statement_parse_nl_rabo_mt940/tests/__init__.py
  24. 5
      bank_statement_parse_nl_rabo_mt940/tests/test_import_bank_statement.py

40
account_bank_statement_import/account_bank_statement_import.py

@ -81,9 +81,9 @@ class AccountBankStatementImport(models.TransientModel):
# Check raw data: # Check raw data:
self._check_parsed_data(statements) self._check_parsed_data(statements)
# Import all statements: # Import all statements:
for statement in statements:
for stmt_vals in statements:
(statement_id, new_notifications) = ( (statement_id, new_notifications) = (
self._import_statement(statement))
self._import_statement(stmt_vals))
if statement_id: if statement_id:
statement_ids.append(statement_id) statement_ids.append(statement_id)
notifications.append(new_notifications) notifications.append(new_notifications)
@ -92,13 +92,13 @@ class AccountBankStatementImport(models.TransientModel):
return statement_ids, notifications return statement_ids, notifications
@api.model @api.model
def _import_statement(self, statement):
def _import_statement(self, stmt_vals):
"""Import a single bank-statement. """Import a single bank-statement.
Return ids of created statements and notifications. Return ids of created statements and notifications.
""" """
currency_code = statement.pop('currency_code')
account_number = statement.pop('account_number')
currency_code = stmt_vals.pop('currency_code')
account_number = stmt_vals.pop('account_number')
# Try to find the bank account and currency in odoo # Try to find the bank account and currency in odoo
currency_id = self._find_currency_id(currency_code) currency_id = self._find_currency_id(currency_code)
bank_account_id = self._find_bank_account_id(account_number) bank_account_id = self._find_bank_account_id(account_number)
@ -118,10 +118,10 @@ class AccountBankStatementImport(models.TransientModel):
if not journal_id: if not journal_id:
raise Warning(_('Can not determine journal for import.')) raise Warning(_('Can not determine journal for import.'))
# Prepare statement data to be used for bank statements creation # Prepare statement data to be used for bank statements creation
statement = self._complete_statement(
statement, journal_id, account_number)
# Create the bank statement
return self._create_bank_statement(statement)
stmt_vals = self._complete_statement(
stmt_vals, journal_id, account_number)
# Create the bank stmt_vals
return self._create_bank_statement(stmt_vals)
@api.model @api.model
def _parse_file(self, data_file): def _parse_file(self, data_file):
@ -164,8 +164,8 @@ class AccountBankStatementImport(models.TransientModel):
""" Basic and structural verifications """ """ Basic and structural verifications """
if len(statements) == 0: if len(statements) == 0:
raise Warning(_('This file doesn\'t contain any statement.')) raise Warning(_('This file doesn\'t contain any statement.'))
for statement in statements:
if 'transactions' in statement and statement['transactions']:
for stmt_vals in statements:
if 'transactions' in stmt_vals and stmt_vals['transactions']:
return return
# If we get here, no transaction was found: # If we get here, no transaction was found:
raise Warning(_('This file doesn\'t contain any transaction.')) raise Warning(_('This file doesn\'t contain any transaction.'))
@ -281,10 +281,10 @@ class AccountBankStatementImport(models.TransientModel):
default_currency=currency_id).create(vals_acc) default_currency=currency_id).create(vals_acc)
@api.model @api.model
def _complete_statement(self, statement, journal_id, account_number):
def _complete_statement(self, stmt_vals, journal_id, account_number):
"""Complete statement from information passed.""" """Complete statement from information passed."""
statement['journal_id'] = journal_id
for line_vals in statement['transactions']:
stmt_vals['journal_id'] = journal_id
for line_vals in stmt_vals['transactions']:
unique_import_id = line_vals.get('unique_import_id', False) unique_import_id = line_vals.get('unique_import_id', False)
if unique_import_id: if unique_import_id:
line_vals['unique_import_id'] = ( line_vals['unique_import_id'] = (
@ -311,10 +311,10 @@ class AccountBankStatementImport(models.TransientModel):
identifying_string).id identifying_string).id
line_vals['partner_id'] = partner_id line_vals['partner_id'] = partner_id
line_vals['bank_account_id'] = bank_account_id line_vals['bank_account_id'] = bank_account_id
return statement
return stmt_vals
@api.model @api.model
def _create_bank_statement(self, statement):
def _create_bank_statement(self, stmt_vals):
""" Create bank statement from imported values, filtering out """ Create bank statement from imported values, filtering out
already imported transactions, and return data used by the already imported transactions, and return data used by the
reconciliation widget reconciliation widget
@ -324,7 +324,7 @@ class AccountBankStatementImport(models.TransientModel):
# Filter out already imported transactions and create statement # Filter out already imported transactions and create statement
ignored_line_ids = [] ignored_line_ids = []
filtered_st_lines = [] filtered_st_lines = []
for line_vals in statement['transactions']:
for line_vals in stmt_vals['transactions']:
unique_id = ( unique_id = (
'unique_import_id' in line_vals and 'unique_import_id' in line_vals and
line_vals['unique_import_id'] line_vals['unique_import_id']
@ -337,13 +337,13 @@ class AccountBankStatementImport(models.TransientModel):
statement_id = False statement_id = False
if len(filtered_st_lines) > 0: if len(filtered_st_lines) > 0:
# Remove values that won't be used to create records # Remove values that won't be used to create records
statement.pop('transactions', None)
stmt_vals.pop('transactions', None)
for line_vals in filtered_st_lines: for line_vals in filtered_st_lines:
line_vals.pop('account_number', None) line_vals.pop('account_number', None)
# Create the statement # Create the statement
statement['line_ids'] = [
stmt_vals['line_ids'] = [
[0, False, line] for line in filtered_st_lines] [0, False, line] for line in filtered_st_lines]
statement_id = bs_model.create(statement).id
statement_id = bs_model.create(stmt_vals).id
# Prepare import feedback # Prepare import feedback
notifications = [] notifications = []
num_ignored = len(ignored_line_ids) num_ignored = len(ignored_line_ids)

49
bank_statement_parse/README.rst

@ -1,6 +1,49 @@
.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
:alt: License: AGPL-3
Bank Statement Parse
====================
This module makes it easy to write parsers for bank statement files, by
providing common functionality. The module is especially usefull for
converting the parsers written for previous versions of OpenERp / Odoo.
Known issues / Roadmap
======================
* None
Bug Tracker
===========
Bugs are tracked on `GitHub Issues <https://github.com/OCA/bank-statement-import/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed feedback
`here <https://github.com/OCA/bank-statement-import/issues/new?body=module:%20account_bank_statement_import%0Aversion:%208.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
Credits
=======
Contributors
------------
* Stefan Rijnhart <srijnhart@therp.nl>
* Ronald Portier <rportier@therp.nl>
Maintainer
----------
.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org
This module is maintained by the OCA.
OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
To contribute to this module, please visit http://odoo-community.org.
This module should make it easy to migrate bank statement import This module should make it easy to migrate bank statement import
modules written for earlies versions of Odoo/OpenERP. modules written for earlies versions of Odoo/OpenERP.
At the same time the utility classes can be used as a reference for the
information that can be present in bank statements and/or bank transactions.

4
bank_statement_parse/__openerp__.py

@ -5,8 +5,6 @@
# #
# All other contributions are (C) by their respective contributors # All other contributions are (C) by their respective contributors
# #
# All Rights Reserved
#
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as # it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the # published by the Free Software Foundation, either version 3 of the
@ -25,7 +23,7 @@
'name': 'Bank Statement Import Parse', 'name': 'Bank Statement Import Parse',
'version': '0.5', 'version': '0.5',
'license': 'AGPL-3', 'license': 'AGPL-3',
'author': 'Banking addons community',
'author': 'Odoo Community Association (OCA), Therp BV',
'website': 'https://github.com/OCA/bank-statement-import', 'website': 'https://github.com/OCA/bank-statement-import',
'category': 'Banking addons', 'category': 'Banking addons',
'depends': [], 'depends': [],

5
bank_statement_parse/parserlib.py

@ -2,8 +2,7 @@
"""Classes and definitions used in parsing bank statements.""" """Classes and definitions used in parsing bank statements."""
############################################################################## ##############################################################################
# #
# Copyright (C) 2015 Therp BV - http://therp.nl.
# All Rights Reserved
# Copyright (C) 2015 Therp BV <http://therp.nl>.
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published by # it under the terms of the GNU Affero General Public License as published by
@ -111,5 +110,3 @@ class BankTransaction(object):
self.storno_retry = False self.storno_retry = False
# If True, make cancelled debit eligible for a next direct debit run # If True, make cancelled debit eligible for a next direct debit run
self.data = '' # Raw data from which the transaction has been parsed self.data = '' # Raw data from which the transaction has been parsed
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

46
bank_statement_parse_camt/README.rst

@ -1,3 +1,49 @@
.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
:alt: License: AGPL-3
Bank Statement Parse Camt
=========================
Module to import SEPA CAMT.053 Format bank statement files. Module to import SEPA CAMT.053 Format bank statement files.
Based on the Banking addons framework. Based on the Banking addons framework.
Known issues / Roadmap
======================
* None
Bug Tracker
===========
Bugs are tracked on `GitHub Issues <https://github.com/OCA/bank-statement-import/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed feedback
`here <https://github.com/OCA/bank-statement-import/issues/new?body=module:%20account_bank_statement_import%0Aversion:%208.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
Credits
=======
Contributors
------------
* Stefan Rijnhart <srijnhart@therp.nl>
* Ronald Portier <rportier@therp.nl>
Maintainer
----------
.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org
This module is maintained by the OCA.
OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
To contribute to this module, please visit http://odoo-community.org.
This module should make it easy to migrate bank statement import
modules written for earlies versions of Odoo/OpenERP.

8
bank_statement_parse_camt/__openerp__.py

@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
############################################################################## ##############################################################################
# #
# Copyright (C) 2013 Therp BV (<http://therp.nl>)
# All Rights Reserved
# Copyright (C) 2013-2015 Therp BV <http://therp.nl>
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published # it under the terms of the GNU Affero General Public License as published
@ -21,8 +21,8 @@
'name': 'CAMT Format Bank Statements Import', 'name': 'CAMT Format Bank Statements Import',
'version': '0.3', 'version': '0.3',
'license': 'AGPL-3', 'license': 'AGPL-3',
'author': 'Therp BV',
'website': 'https://github.com/OCA/banking',
'author': 'Odoo Community Association (OCA), Therp BV',
'website': 'https://github.com/OCA/bank-statement-import',
'category': 'Banking addons', 'category': 'Banking addons',
'depends': [ 'depends': [
'account_bank_statement_import', 'account_bank_statement_import',

5
bank_statement_parse_camt/account_bank_statement_import.py

@ -2,8 +2,7 @@
"""Add process_camt method to account.bank.statement.import.""" """Add process_camt method to account.bank.statement.import."""
############################################################################## ##############################################################################
# #
# Copyright (C) 2013 Therp BV (<http://therp.nl>)
# All Rights Reserved
# Copyright (C) 2013-2015 Therp BV <http://therp.nl>
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published # it under the terms of the GNU Affero General Public License as published
@ -43,5 +42,3 @@ class AccountBankStatementImport(models.TransientModel):
_logger.debug("Statement file was not a camt file.") _logger.debug("Statement file was not a camt file.")
return super(AccountBankStatementImport, self)._parse_file( return super(AccountBankStatementImport, self)._parse_file(
cr, uid, data_file, context=context) cr, uid, data_file, context=context)
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

3
bank_statement_parse_camt/camt.py

@ -3,7 +3,6 @@
############################################################################## ##############################################################################
# #
# Copyright (C) 2013-2015 Therp BV <http://therp.nl> # Copyright (C) 2013-2015 Therp BV <http://therp.nl>
# All Rights Reserved
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published # it under the terms of the GNU Affero General Public License as published
@ -241,5 +240,3 @@ class CamtParser(object):
if len(statement.transactions): if len(statement.transactions):
statements.append(statement) statements.append(statement)
return statements return statements
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

2
bank_statement_parse_camt/tests/__init__.py

@ -6,8 +6,6 @@
# #
# All other contributions are (C) by their respective contributors # All other contributions are (C) by their respective contributors
# #
# All Rights Reserved
#
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as # it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the # published by the Free Software Foundation, either version 3 of the

4
bank_statement_parse_camt/tests/test_import_bank_statement.py

@ -6,8 +6,6 @@
# #
# All other contributions are (C) by their respective contributors # All other contributions are (C) by their respective contributors
# #
# All Rights Reserved
#
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as # it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the # published by the Free Software Foundation, either version 3 of the
@ -64,5 +62,3 @@ class TestStatementFile(TransactionCase):
'Real end balance %f not equal to 15121.12' % 'Real end balance %f not equal to 15121.12' %
statement_obj.balance_end_real statement_obj.balance_end_real
) )
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

53
bank_statement_parse_mt940/README.rst

@ -0,0 +1,53 @@
.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
:alt: License: AGPL-3
Bank Statement MT940
====================
This module provides a generic parser for MT940 files. Given that MT940 is a
non-open non-standard of pure evil in the way that every bank cooks up its own
interpretation of it, this addon alone won't help you much. It is rather
intended to be used by other addons to implement the dialect specific to a
certain bank.
See bank_statement_parse_nl_ing_mt940 for an example on how to use it.
Known issues / Roadmap
======================
* None
Bug Tracker
===========
Bugs are tracked on `GitHub Issues <https://github.com/OCA/bank-statement-import/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed feedback
`here <https://github.com/OCA/bank-statement-import/issues/new?body=module:%20account_bank_statement_import%0Aversion:%208.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
Credits
=======
Contributors
------------
* Stefan Rijnhart <srijnhart@therp.nl>
* Ronald Portier <rportier@therp.nl>
Maintainer
----------
.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org
This module is maintained by the OCA.
OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
To contribute to this module, please visit http://odoo-community.org.
This module should make it easy to migrate bank statement import
modules written for earlies versions of Odoo/OpenERP.

14
bank_statement_parse_mt940/__openerp__.py

@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
############################################################################## ##############################################################################
# #
# Copyright (C) 2013 Therp BV <http://therp.nl>
# All Rights Reserved
# Copyright (C) 2013-2015 Therp BV <http://therp.nl>
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published # it under the terms of the GNU Affero General Public License as published
@ -21,17 +21,9 @@
'name': 'MT940 Bank Statements Import', 'name': 'MT940 Bank Statements Import',
'version': '1.1', 'version': '1.1',
'license': 'AGPL-3', 'license': 'AGPL-3',
'author': 'Therp BV',
'author': 'Odoo Community Association (OCA), Therp BV',
'website': 'https://github.com/OCA/bank-statement-import', 'website': 'https://github.com/OCA/bank-statement-import',
'category': 'Banking addons', 'category': 'Banking addons',
'description': '''
This addon provides a generic parser for MT940 files. Given that MT940 is a
non-open non-standard of pure evil in the way that every bank cooks up its own
interpretation of it, this addon alone won't help you much. It is rather
intended to be used by other addons to implement the dialect specific to a
certain bank.
See bank_statement_parse_nl_ing_mt940 for an example on how to use it.
''',
'depends': [ 'depends': [
'account_bank_statement_import', 'account_bank_statement_import',
'bank_statement_parse', 'bank_statement_parse',

5
bank_statement_parse_mt940/mt940.py

@ -1,10 +1,9 @@
#!/usr/bin/env python2
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
"""Generic parser for MT940 files, base for customized versions per bank.""" """Generic parser for MT940 files, base for customized versions per bank."""
############################################################################## ##############################################################################
# #
# OpenERP, Open Source Management Solution # OpenERP, Open Source Management Solution
# This module copyright (C) 2014 Therp BV (<http://therp.nl>).
# This module copyright (C) 2014-2015 Therp BV <http://therp.nl>.
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as # it under the terms of the GNU Affero General Public License as
@ -269,5 +268,3 @@ class MT940(object):
"""details for previous transaction, here most differences between """details for previous transaction, here most differences between
banks occur""" banks occur"""
pass pass
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

50
bank_statement_parse_nl_ing_mt940/README.rst

@ -1,3 +1,6 @@
.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
:alt: License: AGPL-3
Import MT940 IBAN ING Bank Statements Import MT940 IBAN ING Bank Statements
===================================== =====================================
@ -7,19 +10,42 @@ The specifications are published at:
https://www.ing.nl/media/ING_ming_mt940s_24_juli_tcm162-46356.pdf https://www.ing.nl/media/ING_ming_mt940s_24_juli_tcm162-46356.pdf
and were last updated august 2014. and were last updated august 2014.
Installation
============
Known issues / Roadmap
======================
* None
Bug Tracker
===========
Bugs are tracked on `GitHub Issues <https://github.com/OCA/bank-statement-import/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed feedback
`here <https://github.com/OCA/bank-statement-import/issues/new?body=module:%20account_bank_statement_import%0Aversion:%208.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
Credits
=======
Contributors
------------
* Stefan Rijnhart <srijnhart@therp.nl>
* Ronald Portier <rportier@therp.nl>
Maintainer
----------
This module is available:
* for Odoo version 8: in the OCA project bank-statement-import:
https://github.com/OCA/bank-statement-import
.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org
Configuration
=============
This module is maintained by the OCA.
In the menu Accounting > Configuration > Accounts > Setup your Bank Accounts,
make sure that you have your ING bank account with the following parameters:
OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
* Bank Account Type: Normal Bank Account
* Account Number: the bank account number also appearing in the statements
* Account Journal: the journal associated to your bank account
To contribute to this module, please visit http://odoo-community.org.
This module should make it easy to migrate bank statement import
modules written for earlies versions of Odoo/OpenERP.

8
bank_statement_parse_nl_ing_mt940/__openerp__.py

@ -1,7 +1,7 @@
# -*- coding: utf-8 -*-
############################################################################## ##############################################################################
# #
# Copyright (C) 2013 Therp BV (<http://therp.nl>)
# All Rights Reserved
# Copyright (C) 2013-2015 Therp BV <http://therp.nl>
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published # it under the terms of the GNU Affero General Public License as published
@ -21,8 +21,8 @@
'name': 'MT940 IBAN ING Format Bank Statements Import', 'name': 'MT940 IBAN ING Format Bank Statements Import',
'version': '0.3', 'version': '0.3',
'license': 'AGPL-3', 'license': 'AGPL-3',
'author': 'Therp BV',
'website': 'https://github.com/OCA/banking',
'author': 'Odoo Community Association (OCA), Therp BV',
'website': 'https://github.com/OCA/bank-statement-import',
'category': 'Banking addons', 'category': 'Banking addons',
'depends': [ 'depends': [
'bank_statement_parse_mt940' 'bank_statement_parse_mt940'

7
bank_statement_parse_nl_ing_mt940/account_bank_statement_import.py

@ -1,9 +1,8 @@
# -*- coding: utf-8 -*- # -*- coding: utf-8 -*-
"""Parse a MT940 IBAN ING file."""
"""Parse a MT940 ING file."""
############################################################################## ##############################################################################
# #
# Copyright (C) 2013 Therp BV (<http://therp.nl>)
# All Rights Reserved
# Copyright (C) 2013-2015 Therp BV <http://therp.nl>
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published # it under the terms of the GNU Affero General Public License as published
@ -43,5 +42,3 @@ class AccountBankStatementImport(models.TransientModel):
_logger.debug("Statement file was not a MT940 IBAN ING file.") _logger.debug("Statement file was not a MT940 IBAN ING file.")
return super(AccountBankStatementImport, self)._parse_file( return super(AccountBankStatementImport, self)._parse_file(
cr, uid, data_file, context=context) cr, uid, data_file, context=context)
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

3
bank_statement_parse_nl_ing_mt940/mt940.py

@ -3,7 +3,6 @@
############################################################################## ##############################################################################
# #
# Copyright (C) 2014-2015 Therp BV <http://therp.nl>. # Copyright (C) 2014-2015 Therp BV <http://therp.nl>.
# All Rights Reserved
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published # it under the terms of the GNU Affero General Public License as published
@ -65,5 +64,3 @@ class MT940Parser(MT940):
handle_common_subfields(transaction, subfields) handle_common_subfields(transaction, subfields)
# Prevent handling tag 86 later for non transaction details: # Prevent handling tag 86 later for non transaction details:
self.current_transaction = None self.current_transaction = None
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

4
bank_statement_parse_nl_ing_mt940/tests/test_import_bank_statement.py

@ -6,8 +6,6 @@
# #
# All other contributions are (C) by their respective contributors # All other contributions are (C) by their respective contributors
# #
# All Rights Reserved
#
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as # it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the # published by the Free Software Foundation, either version 3 of the
@ -83,5 +81,3 @@ class TestStatementFile(TransactionCase):
'test-ing.940', 'NL77INGB0574908765-2014-02-20', 'test-ing.940', 'NL77INGB0574908765-2014-02-20',
662.23, 564.35 662.23, 564.35
) )
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

47
bank_statement_parse_nl_rabo_mt940/README.rst

@ -0,0 +1,47 @@
.. image:: https://img.shields.io/badge/licence-AGPL--3-blue.svg
:alt: License: AGPL-3
Bank Statement NL Rabobank MT940
================================
This addon imports the structured MT940 format as offered by
the dutch Rabobank.
Known issues / Roadmap
======================
* None
Bug Tracker
===========
Bugs are tracked on `GitHub Issues <https://github.com/OCA/bank-statement-import/issues>`_.
In case of trouble, please check there if your issue has already been reported.
If you spotted it first, help us smashing it by providing a detailed and welcomed feedback
`here <https://github.com/OCA/bank-statement-import/issues/new?body=module:%20account_bank_statement_import%0Aversion:%208.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
Credits
=======
Contributors
------------
* Ronald Portier <rportier@therp.nl>
Maintainer
----------
.. image:: https://odoo-community.org/logo.png
:alt: Odoo Community Association
:target: https://odoo-community.org
This module is maintained by the OCA.
OCA, or the Odoo Community Association, is a nonprofit organization whose
mission is to support the collaborative development of Odoo features and
promote its widespread use.
To contribute to this module, please visit http://odoo-community.org.
This module should make it easy to migrate bank statement import
modules written for earlies versions of Odoo/OpenERP.

10
bank_statement_parse_nl_rabo_mt940/__openerp__.py

@ -2,7 +2,7 @@
############################################################################## ##############################################################################
# #
# OpenERP, Open Source Management Solution # OpenERP, Open Source Management Solution
# This module copyright (C) 2014 Therp BV (<http://therp.nl>).
# This module copyright (C) 2014-2015 Therp BV <http://therp.nl>.
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as # it under the terms of the GNU Affero General Public License as
@ -21,12 +21,8 @@
{ {
"name": "MT940 import for dutch Rabobank", "name": "MT940 import for dutch Rabobank",
"version": "1.1", "version": "1.1",
"author": "Therp BV,Odoo Community Association (OCA)",
"complexity": "normal",
"description": """
This addon imports the structured MT940 format as offered by the dutch
Rabobank.
""",
'author': 'Odoo Community Association (OCA), Therp BV',
'website': 'https://github.com/OCA/bank-statement-import',
"category": "Account Banking", "category": "Account Banking",
"depends": [ "depends": [
'bank_statement_parse_mt940' 'bank_statement_parse_mt940'

5
bank_statement_parse_nl_rabo_mt940/account_bank_statement_import.py

@ -2,8 +2,7 @@
"""Parse a MT940 RABO file.""" """Parse a MT940 RABO file."""
############################################################################## ##############################################################################
# #
# Copyright (C) 2013 Therp BV <http://therp.nl>
# All Rights Reserved
# Copyright (C) 2013-2015 Therp BV <http://therp.nl>
# #
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as published # it under the terms of the GNU Affero General Public License as published
@ -43,5 +42,3 @@ class AccountBankStatementImport(models.TransientModel):
_logger.debug("Statement file was not a MT940 RABO file.") _logger.debug("Statement file was not a MT940 RABO file.")
return super(AccountBankStatementImport, self)._parse_file( return super(AccountBankStatementImport, self)._parse_file(
cr, uid, data_file, context=context) cr, uid, data_file, context=context)
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

2
bank_statement_parse_nl_rabo_mt940/mt940.py

@ -85,5 +85,3 @@ class MT940Parser(MT940):
transaction.remote_owner_address = subfields['ADDR'] transaction.remote_owner_address = subfields['ADDR']
# Prevent handling tag 86 later for non transaction details: # Prevent handling tag 86 later for non transaction details:
self.current_transaction = None self.current_transaction = None
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:

2
bank_statement_parse_nl_rabo_mt940/tests/__init__.py

@ -6,8 +6,6 @@
# #
# All other contributions are (C) by their respective contributors # All other contributions are (C) by their respective contributors
# #
# All Rights Reserved
#
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as # it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the # published by the Free Software Foundation, either version 3 of the

5
bank_statement_parse_nl_rabo_mt940/tests/test_import_bank_statement.py

@ -3,11 +3,8 @@
############################################################################## ##############################################################################
# #
# Copyright (C) 2015 Therp BV <http://therp.nl>. # Copyright (C) 2015 Therp BV <http://therp.nl>.
#
# All other contributions are (C) by their respective contributors # All other contributions are (C) by their respective contributors
# #
# All Rights Reserved
#
# This program is free software: you can redistribute it and/or modify # This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU Affero General Public License as # it under the terms of the GNU Affero General Public License as
# published by the Free Software Foundation, either version 3 of the # published by the Free Software Foundation, either version 3 of the
@ -77,5 +74,3 @@ class TestStatementFile(TransactionCase):
'Real end balance %f not equal to 4798.91' % 'Real end balance %f not equal to 4798.91' %
statement_obj.balance_end_real statement_obj.balance_end_real
) )
# vim:expandtab:smartindent:tabstop=4:softtabstop=4:shiftwidth=4:
Loading…
Cancel
Save