From ff2dd80b96df83f69397435490c41883ad3bd9dd Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Wed, 15 May 2019 12:39:24 +0300 Subject: [PATCH 01/32] [ADD] account_bank_statement_import_online: online bank statements [UPD] Update account_bank_statement_import_online.pot [UPD] README.rst [ADD] icon.png --- .../README.rst | 114 +++++ .../__init__.py | 5 + .../__manifest__.py | 30 ++ .../account_bank_statement_import_online.xml | 21 + .../account_bank_statement_import_online.pot | 453 +++++++++++++++++ .../models/__init__.py | 4 + .../models/account_journal.py | 96 ++++ .../models/online_bank_statement_provider.py | 388 +++++++++++++++ .../readme/CONFIGURE.rst | 23 + .../readme/CONTRIBUTORS.rst | 1 + .../readme/DESCRIPTION.rst | 1 + .../readme/USAGE.rst | 9 + .../security/ir.model.access.csv | 3 + .../online_bank_statement_provider.xml | 16 + .../static/description/icon.png | Bin 0 -> 9455 bytes .../static/description/index.html | 460 ++++++++++++++++++ .../tests/__init__.py | 3 + .../online_bank_statement_provider_dummy.py | 55 +++ ...st_account_bank_statement_import_online.py | 343 +++++++++++++ .../views/account_journal.xml | 120 +++++ .../views/online_bank_statement_provider.xml | 96 ++++ .../wizards/__init__.py | 3 + .../online_bank_statement_pull_wizard.py | 34 ++ .../online_bank_statement_pull_wizard.xml | 32 ++ 24 files changed, 2310 insertions(+) create mode 100644 account_bank_statement_import_online/README.rst create mode 100644 account_bank_statement_import_online/__init__.py create mode 100644 account_bank_statement_import_online/__manifest__.py create mode 100644 account_bank_statement_import_online/data/account_bank_statement_import_online.xml create mode 100644 account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot create mode 100644 account_bank_statement_import_online/models/__init__.py create mode 100644 account_bank_statement_import_online/models/account_journal.py create mode 100644 account_bank_statement_import_online/models/online_bank_statement_provider.py create mode 100644 account_bank_statement_import_online/readme/CONFIGURE.rst create mode 100644 account_bank_statement_import_online/readme/CONTRIBUTORS.rst create mode 100644 account_bank_statement_import_online/readme/DESCRIPTION.rst create mode 100644 account_bank_statement_import_online/readme/USAGE.rst create mode 100644 account_bank_statement_import_online/security/ir.model.access.csv create mode 100644 account_bank_statement_import_online/security/online_bank_statement_provider.xml create mode 100644 account_bank_statement_import_online/static/description/icon.png create mode 100644 account_bank_statement_import_online/static/description/index.html create mode 100644 account_bank_statement_import_online/tests/__init__.py create mode 100644 account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py create mode 100644 account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py create mode 100644 account_bank_statement_import_online/views/account_journal.xml create mode 100644 account_bank_statement_import_online/views/online_bank_statement_provider.xml create mode 100644 account_bank_statement_import_online/wizards/__init__.py create mode 100644 account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py create mode 100644 account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.xml diff --git a/account_bank_statement_import_online/README.rst b/account_bank_statement_import_online/README.rst new file mode 100644 index 00000000..9cbdefae --- /dev/null +++ b/account_bank_statement_import_online/README.rst @@ -0,0 +1,114 @@ +====================== +Online Bank Statements +====================== + +.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! This file is generated by oca-gen-addon-readme !! + !! changes will be overwritten. !! + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + +.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png + :target: https://odoo-community.org/page/development-status + :alt: Beta +.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png + :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html + :alt: License: AGPL-3 +.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fbank--statement--import-lightgray.png?logo=github + :target: https://github.com/OCA/bank-statement-import/tree/12.0/account_bank_statement_import_online + :alt: OCA/bank-statement-import +.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png + :target: https://translation.odoo-community.org/projects/bank-statement-import-12-0/bank-statement-import-12-0-account_bank_statement_import_online + :alt: Translate me on Weblate +.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png + :target: https://runbot.odoo-community.org/runbot/174/12.0 + :alt: Try me on Runbot + +|badge1| |badge2| |badge3| |badge4| |badge5| + +This module provides base for building online bank statements providers. + +**Table of contents** + +.. contents:: + :local: + +Configuration +============= + +To configure online bank statements provider: + +#. Go to *Invoicing > Configuration > Bank Accounts* +#. Open bank account to configure and edit it +#. Set *Bank Feeds* to *Online* +#. Select online bank statements provider in *Online Bank Statements (OCA)* + section +#. Save the bank account +#. Click on provider and configure provider-specific settings. + +or, alternatively: + +#. Go to *Invoicing > Overview* +#. Open settings of the corresponding journal account +#. Switch to *Bank Account* tab +#. Set *Bank Feeds* to *Online* +#. Select online bank statements provider in *Online Bank Statements (OCA)* + section +#. Save the bank account +#. Click on provider and configure provider-specific settings. + +**NOTE**: To access these features, user needs to belong to +*Show Full Accounting Features* group. + +Usage +===== + +To pull historical bank statements: + +#. Go to *Invoicing > Configuration > Bank Accounts* +#. Select specific bank accounts +#. Launch *Actions > Online Bank Statements Pull Wizard* +#. Configure date interval and click *Pull* + +**NOTE**: To access these features, user needs to belong to +*Show Full Accounting Features* group. + +Bug Tracker +=========== + +Bugs are tracked on `GitHub 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 `_. + +Do not contact contributors directly about support or help with technical issues. + +Credits +======= + +Authors +~~~~~~~ + +* Brainbean Apps +* Dataplug + +Contributors +~~~~~~~~~~~~ + +* Alexey Pelykh + +Maintainers +~~~~~~~~~~~ + +This module is maintained by the OCA. + +.. image:: https://odoo-community.org/logo.png + :alt: Odoo Community Association + :target: https://odoo-community.org + +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. + +This module is part of the `OCA/bank-statement-import `_ project on GitHub. + +You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/account_bank_statement_import_online/__init__.py b/account_bank_statement_import_online/__init__.py new file mode 100644 index 00000000..a82a91d6 --- /dev/null +++ b/account_bank_statement_import_online/__init__.py @@ -0,0 +1,5 @@ +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from . import models +from . import wizards +from .tests import online_bank_statement_provider_dummy diff --git a/account_bank_statement_import_online/__manifest__.py b/account_bank_statement_import_online/__manifest__.py new file mode 100644 index 00000000..c614dd47 --- /dev/null +++ b/account_bank_statement_import_online/__manifest__.py @@ -0,0 +1,30 @@ +# Copyright 2019 Brainbean Apps (https://brainbeanapps.com) +# Copyright 2019 Dataplug (https://dataplug.io) +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +{ + 'name': 'Online Bank Statements', + 'version': '12.0.1.0.0', + 'author': + 'Brainbean Apps, ' + 'Dataplug, ' + 'Odoo Community Association (OCA)', + 'website': 'https://github.com/OCA/bank-statement-import/', + 'license': 'AGPL-3', + 'category': 'Accounting', + 'summary': 'Online bank statements update', + 'depends': [ + 'account', + 'account_bank_statement_import', + 'web_widget_dropdown_dynamic', + ], + 'data': [ + 'data/account_bank_statement_import_online.xml', + 'security/ir.model.access.csv', + 'security/online_bank_statement_provider.xml', + 'views/account_journal.xml', + 'views/online_bank_statement_provider.xml', + 'wizards/online_bank_statement_pull_wizard.xml', + ], + 'installable': True, +} diff --git a/account_bank_statement_import_online/data/account_bank_statement_import_online.xml b/account_bank_statement_import_online/data/account_bank_statement_import_online.xml new file mode 100644 index 00000000..63add6d2 --- /dev/null +++ b/account_bank_statement_import_online/data/account_bank_statement_import_online.xml @@ -0,0 +1,21 @@ + + + + + + Pull Online Bank Statements + 1 + hours + -1 + code + 2019-01-01 00:10:00 + + + model._scheduled_pull() + + + diff --git a/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot b/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot new file mode 100644 index 00000000..3d9d353f --- /dev/null +++ b/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot @@ -0,0 +1,453 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * account_bank_statement_import_online +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 12.0\n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: <>\n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: account_bank_statement_import_online +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:140 +#, python-format +msgid "%(number)s %(type)s" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__account_number +msgid "Account Number" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction +msgid "Action Needed" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__active +msgid "Active" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__api_base +msgid "Api Base" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_attachment_count +msgid "Attachment Count" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Cancel" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate +msgid "Certificate" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_chain +msgid "Certificate Chain" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_private_key +msgid "Certificate Private Key" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_public_key +msgid "Certificate Public Key" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__company_id +msgid "Company" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__company_id +msgid "Company related to this journal" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form +msgid "Configuration" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__create_uid +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__create_uid +msgid "Created by" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__create_date +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__create_date +msgid "Created on" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__currency_id +msgid "Currency" +msgstr "" + +#. module: account_bank_statement_import_online +#: selection:online.bank.statement.provider,statement_creation_mode:0 +msgid "Daily statements" +msgstr "" + +#. module: account_bank_statement_import_online +#: selection:online.bank.statement.provider,interval_type:0 +msgid "Day(s)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form +msgid "Details" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__display_name +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__display_name +msgid "Display Name" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_follower_ids +msgid "Followers" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_channel_ids +msgid "Followers (Channels)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_partner_ids +msgid "Followers (Partners)" +msgstr "" + +#. module: account_bank_statement_import_online +#: selection:online.bank.statement.provider,interval_type:0 +msgid "Hour(s)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__id +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__id +msgid "ID" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread +msgid "If checked new messages require your attention." +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction +msgid "If checked, new messages require your attention." +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error +msgid "If checked, some messages have a delivery error." +msgstr "" + +#. module: account_bank_statement_import_online +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:137 +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_filter +#, python-format +msgid "Inactive" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__interval_type +msgid "Interval Type" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_is_follower +msgid "Is Follower" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model,name:account_bank_statement_import_online.model_account_journal +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__journal_id +msgid "Journal" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__key +msgid "Key" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider____last_update +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard____last_update +msgid "Last Modified on" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__write_uid +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__write_uid +msgid "Last Updated by" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__write_date +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__write_date +msgid "Last Updated on" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__last_successful_run +msgid "Last successful pull" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_main_attachment_id +msgid "Main Attachment" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error +msgid "Message Delivery error" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_ids +msgid "Messages" +msgstr "" + +#. module: account_bank_statement_import_online +#: selection:online.bank.statement.provider,interval_type:0 +msgid "Minute(s)" +msgstr "" + +#. module: account_bank_statement_import_online +#: selection:online.bank.statement.provider,statement_creation_mode:0 +msgid "Monthly statements" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__name +msgid "Name" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__next_run +msgid "Next scheduled pull" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction_counter +msgid "Number of Actions" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error_counter +msgid "Number of error" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction_counter +msgid "Number of messages which requires an action" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error_counter +msgid "Number of messages with delivery error" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread_counter +msgid "Number of unread messages" +msgstr "" + +#. module: account_bank_statement_import_online +#: code:addons/account_bank_statement_import_online/models/account_journal.py:29 +#, python-format +msgid "Online (OCA)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model,name:account_bank_statement_import_online.model_online_bank_statement_provider +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_journal__online_bank_statement_provider +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form +msgid "Online Bank Statement Provider" +msgstr "" + +#. module: account_bank_statement_import_online +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:182 +#, python-format +msgid "Online Bank Statement Provider \"%s\" failed to obtain statement data since %s until %s:\n" +"%s" +msgstr "" + +#. module: account_bank_statement_import_online +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:191 +#, python-format +msgid "Online Bank Statement Provider failure" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_filter +msgid "Online Bank Statement Providers" +msgstr "" + +#. module: account_bank_statement_import_online +#: code:addons/account_bank_statement_import_online/models/account_journal.py:88 +#: model:ir.model,name:account_bank_statement_import_online.model_online_bank_statement_pull_wizard +#, python-format +msgid "Online Bank Statement Pull Wizard" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_bank_journal_form +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_journal_form +msgid "Online Bank Statements (OCA)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.actions.server,name:account_bank_statement_import_online.action_online_bank_statements_pull_wizard +msgid "Online Bank Statements Pull Wizard" +msgstr "" + +#. module: account_bank_statement_import_online +#: sql_constraint:online.bank.statement.provider:0 +msgid "Only one online banking statement provider per journal!" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__origin +msgid "Origin" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__passphrase +msgid "Passphrase" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__password +msgid "Password" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_bank_journal_form +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_journal_form +msgid "Provider" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__provider_ids +msgid "Providers" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Pull" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.actions.server,name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements_ir_actions_server +#: model:ir.cron,cron_name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements +#: model:ir.cron,name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements +msgid "Pull Online Bank Statements" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form +msgid "Scheduled Pull" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__interval_number +msgid "Scheduled update interval" +msgstr "" + +#. module: account_bank_statement_import_online +#: sql_constraint:online.bank.statement.provider:0 +msgid "Scheduled update interval must be greater than zero!" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__service +msgid "Service" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__date_since +msgid "Since" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__statement_creation_mode +msgid "Statement Creation Mode" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_journal__online_bank_statement_provider_id +msgid "Statement Provider" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__currency_id +msgid "The currency used to enter statement" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread +msgid "Unread Messages" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread_counter +msgid "Unread Messages Counter" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__date_until +msgid "Until" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__update_schedule +msgid "Update Schedule" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__username +msgid "Username" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__website_message_ids +msgid "Website Messages" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__website_message_ids +msgid "Website communication history" +msgstr "" + +#. module: account_bank_statement_import_online +#: selection:online.bank.statement.provider,interval_type:0 +msgid "Week(s)" +msgstr "" + +#. module: account_bank_statement_import_online +#: selection:online.bank.statement.provider,statement_creation_mode:0 +msgid "Weekly statements" +msgstr "" + diff --git a/account_bank_statement_import_online/models/__init__.py b/account_bank_statement_import_online/models/__init__.py new file mode 100644 index 00000000..56bd827c --- /dev/null +++ b/account_bank_statement_import_online/models/__init__.py @@ -0,0 +1,4 @@ +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from . import account_journal +from . import online_bank_statement_provider diff --git a/account_bank_statement_import_online/models/account_journal.py b/account_bank_statement_import_online/models/account_journal.py new file mode 100644 index 00000000..cca7974b --- /dev/null +++ b/account_bank_statement_import_online/models/account_journal.py @@ -0,0 +1,96 @@ +# Copyright 2019 Brainbean Apps (https://brainbeanapps.com) +# Copyright 2019 Dataplug (https://dataplug.io) +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). + +import logging + +from odoo import models, fields, api, _ + +_logger = logging.getLogger(__name__) + + +class AccountJournal(models.Model): + _inherit = 'account.journal' + + online_bank_statement_provider = fields.Selection( + selection=lambda self: self.env[ + 'account.journal' + ]._selection_online_bank_statement_provider(), + ) + online_bank_statement_provider_id = fields.Many2one( + string='Statement Provider', + comodel_name='online.bank.statement.provider', + ondelete='restrict', + copy=False, + ) + + def __get_bank_statements_available_sources(self): + result = super().__get_bank_statements_available_sources() + result.append(('online', _('Online (OCA)'))) + return result + + @api.model + def _selection_online_bank_statement_provider(self): + return self.env[ + 'online.bank.statement.provider' + ]._get_available_services() + [('dummy', 'Dummy')] + + @api.model + def values_online_bank_statement_provider(self): + return self.env[ + 'online.bank.statement.provider' + ]._get_available_services() + + @api.multi + def _update_online_bank_statement_provider_id(self): + OnlineBankStatementProvider = ( + self.env['online.bank.statement.provider'] + ) + for journal in self.filtered('id'): + provider_id = journal.online_bank_statement_provider_id + if journal.bank_statements_source != 'online': + journal.online_bank_statement_provider_id = False + if provider_id: + provider_id.unlink() + continue + if provider_id.service == journal.online_bank_statement_provider: + continue + journal.online_bank_statement_provider_id = False + if provider_id: + provider_id.unlink() + journal.online_bank_statement_provider_id = ( + OnlineBankStatementProvider.create({ + 'journal_id': journal.id, + 'service': journal.online_bank_statement_provider, + }) + ) + + @api.model + def create(self, vals): + rec = super().create(vals) + if 'bank_statements_source' in vals \ + or 'online_bank_statement_provider' in vals: + rec._update_online_bank_statement_provider_id() + return rec + + @api.multi + def write(self, vals): + res = super().write(vals) + if 'bank_statements_source' in vals \ + or 'online_bank_statement_provider' in vals: + self._update_online_bank_statement_provider_id() + return res + + @api.multi + def action_online_bank_statements_pull_wizard(self): + provider_ids = self.mapped('online_bank_statement_provider_id').ids + return { + 'name': _('Online Bank Statement Pull Wizard'), + 'type': 'ir.actions.act_window', + 'res_model': 'online.bank.statement.pull.wizard', + 'views': [[False, 'form']], + 'target': 'new', + 'context': { + 'default_provider_ids': [(6, False, provider_ids)], + }, + } diff --git a/account_bank_statement_import_online/models/online_bank_statement_provider.py b/account_bank_statement_import_online/models/online_bank_statement_provider.py new file mode 100644 index 00000000..6efb8343 --- /dev/null +++ b/account_bank_statement_import_online/models/online_bank_statement_provider.py @@ -0,0 +1,388 @@ +# Copyright 2019 Brainbean Apps (https://brainbeanapps.com) +# Copyright 2019 Dataplug (https://dataplug.io) +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). + +from dateutil.relativedelta import relativedelta, MO +from decimal import Decimal +import logging + +from odoo import models, fields, api, _ +from odoo.addons.base.models.res_bank import sanitize_account_number + +_logger = logging.getLogger(__name__) + + +class OnlineBankStatementProvider(models.Model): + _name = 'online.bank.statement.provider' + _inherit = ['mail.thread'] + _description = 'Online Bank Statement Provider' + + company_id = fields.Many2one( + related='journal_id.company_id', + store=True, + ) + active = fields.Boolean() + name = fields.Char( + string='Name', + compute='_compute_name', + store=True, + ) + journal_id = fields.Many2one( + comodel_name='account.journal', + required=True, + readonly=True, + ondelete='cascade', + domain=[ + ('type', '=', 'bank'), + ], + ) + currency_id = fields.Many2one( + related='journal_id.currency_id', + ) + account_number = fields.Char( + related='journal_id.bank_account_id.acc_number' + ) + service = fields.Selection( + selection=lambda self: self._selection_service(), + required=True, + readonly=True, + ) + interval_type = fields.Selection( + selection=[ + ('minutes', 'Minute(s)'), + ('hours', 'Hour(s)'), + ('days', 'Day(s)'), + ('weeks', 'Week(s)'), + ], + default='hours', + required=True, + ) + interval_number = fields.Integer( + string='Scheduled update interval', + default=1, + required=True, + ) + update_schedule = fields.Char( + string='Update Schedule', + compute='_compute_update_schedule', + ) + last_successful_run = fields.Datetime( + string='Last successful pull', + ) + next_run = fields.Datetime( + string='Next scheduled pull', + default=fields.Datetime.now, + required=True, + ) + statement_creation_mode = fields.Selection( + selection=[ + ('daily', 'Daily statements'), + ('weekly', 'Weekly statements'), + ('monthly', 'Monthly statements'), + ], + default='daily', + required=True, + ) + api_base = fields.Char() + origin = fields.Char() + username = fields.Char() + password = fields.Char() + key = fields.Binary() + certificate = fields.Binary() + passphrase = fields.Char() + certificate_public_key = fields.Text() + certificate_private_key = fields.Text() + certificate_chain = fields.Text() + + _sql_constraints = [ + ( + 'journal_id_uniq', + 'UNIQUE(journal_id)', + 'Only one online banking statement provider per journal!' + ), + ( + 'valid_interval_number', + 'CHECK(interval_number > 0)', + 'Scheduled update interval must be greater than zero!' + ) + ] + + @api.model + def _get_available_services(self): + """Hook for extension""" + return [] + + @api.model + def _selection_service(self): + return self._get_available_services() + [('dummy', 'Dummy')] + + @api.model + def values_service(self): + return self._get_available_services() + + @api.multi + @api.depends('service') + def _compute_name(self): + for provider in self: + provider.name = list(filter( + lambda x: x[0] == provider.service, + self._selection_service() + ))[0][1] + + @api.multi + @api.depends('active', 'interval_type', 'interval_number') + def _compute_update_schedule(self): + for provider in self: + if not provider.active: + provider.update_schedule = _('Inactive') + continue + + provider.update_schedule = _('%(number)s %(type)s') % { + 'number': provider.interval_number, + 'type': list(filter( + lambda x: x[0] == provider.interval_type, + self._fields['interval_type'].selection + ))[0][1], + } + + @api.multi + def _pull(self, date_since, date_until): + AccountBankStatement = self.env['account.bank.statement'] + is_scheduled = self.env.context.get('scheduled') + if is_scheduled: + AccountBankStatement = AccountBankStatement.with_context( + tracking_disable=True, + ) + AccountBankStatementLine = self.env['account.bank.statement.line'] + for provider in self: + statement_date_since = provider._get_statement_date_since( + date_since + ) + while statement_date_since < date_until: + statement_date_until = ( + statement_date_since + provider._get_statement_date_step() + ) + try: + data = provider._obtain_statement_data( + statement_date_since, + statement_date_until + ) + except Exception as e: + if is_scheduled: + _logger.warning( + 'Online Bank Statement Provider "%s" failed to' + ' obtain statement data since %s until %s' % ( + provider.name, + statement_date_since, + statement_date_until, + ), + exc_info=True, + ) + provider.message_post( + body=_( + 'Online Bank Statement Provider "%s" failed to' + ' obtain statement data since %s until %s:\n%s' + ) % ( + provider.name, + statement_date_since, + statement_date_until, + str(e), + ), + subject=_( + 'Online Bank Statement Provider failure' + ), + ) + break + raise + statement_date = provider._get_statement_date( + statement_date_since, + statement_date_until, + ) + if not data: + statement_date_since = statement_date_until + continue + lines_data, statement_values = data + statement = AccountBankStatement.search([ + ('journal_id', '=', provider.journal_id.id), + ('state', '=', 'open'), + ('date', '=', statement_date), + ], limit=1) + if not statement: + statement_values.update({ + 'name': provider.journal_id.sequence_id.with_context( + ir_sequence_date=statement_date, + ).next_by_id(), + 'journal_id': provider.journal_id.id, + 'date': statement_date, + }) + statement = AccountBankStatement.create( + # NOTE: This is needed since create() alters values + statement_values.copy() + ) + filtered_lines = [] + for line_values in lines_data: + date = fields.Datetime.from_string(line_values['date']) + if date < statement_date_since: + if 'balance_start' in statement_values: + statement_values['balance_start'] = ( + Decimal( + statement_values['balance_start'] + ) + Decimal( + line_values['amount'] + ) + ) + continue + elif date >= statement_date_until: + if 'balance_end_real' in statement_values: + statement_values['balance_end_real'] = ( + Decimal( + statement_values['balance_end_real'] + ) - Decimal( + line_values['amount'] + ) + ) + continue + elif date <= date_since or date > date_until: + continue + unique_import_id = line_values.get('unique_import_id') + if unique_import_id: + unique_import_id = provider._generate_unique_import_id( + unique_import_id + ) + line_values.update({ + 'unique_import_id': unique_import_id, + }) + if AccountBankStatementLine.sudo().search( + [('unique_import_id', '=', unique_import_id)], + limit=1): + continue + filtered_lines.append(line_values) + statement_values.update({ + 'line_ids': [[0, False, line] for line in filtered_lines], + }) + if 'balance_start' in statement_values: + statement_values['balance_start'] = float( + statement_values['balance_start'] + ) + if 'balance_start' in statement_values: + statement_values['balance_start'] = float( + statement_values['balance_start'] + ) + statement.write(statement_values) + statement_date_since = statement_date_until + if is_scheduled: + provider._schedule_next_run() + + @api.multi + def _schedule_next_run(self): + self.ensure_one() + self.last_successful_run = self.next_run + self.next_run += self._get_next_run_period() + + @api.multi + def _get_statement_date_since(self, date): + self.ensure_one() + date = date.replace( + hour=0, + minute=0, + second=0, + microsecond=0, + ) + if self.statement_creation_mode == 'daily': + return date + elif self.statement_creation_mode == 'weekly': + return date + relativedelta(weekday=MO(-1)) + elif self.statement_creation_mode == 'monthly': + return date.replace( + day=1, + ) + + @api.multi + def _get_statement_date_step(self): + self.ensure_one() + if self.statement_creation_mode == 'daily': + return relativedelta( + days=1, + hour=0, + minute=0, + second=0, + microsecond=0, + ) + elif self.statement_creation_mode == 'weekly': + return relativedelta( + weeks=1, + weekday=MO, + hour=0, + minute=0, + second=0, + microsecond=0, + ) + elif self.statement_creation_mode == 'monthly': + return relativedelta( + months=1, + day=1, + hour=0, + minute=0, + second=0, + microsecond=0, + ) + + @api.multi + def _get_statement_date(self, date_since, date_until): + self.ensure_one() + # NOTE: Statement date is treated by Odoo as start of period. Details + # - addons/account/models/account_journal_dashboard.py + # - def get_line_graph_datas() + return date_since.date() + + @api.multi + def _generate_unique_import_id(self, unique_import_id): + self.ensure_one() + sanitized_account_number = sanitize_account_number(self.account_number) + return ( + sanitized_account_number and sanitized_account_number + '-' or '' + ) + str(self.journal_id.id) + '-' + unique_import_id + + @api.multi + def _get_next_run_period(self): + self.ensure_one() + if self.interval_type == 'minutes': + return relativedelta(minutes=self.interval_number) + elif self.interval_type == 'hours': + return relativedelta(hours=self.interval_number) + elif self.interval_type == 'days': + return relativedelta(days=self.interval_number) + elif self.interval_type == 'weeks': + return relativedelta(weeks=self.interval_number) + + @api.model + def _scheduled_pull(self): + _logger.info('Scheduled pull of online bank statements...') + + providers = self.search([ + ('active', '=', True), + ('next_run', '<=', fields.Datetime.now()), + ]) + if providers: + _logger.info('Pulling online bank statements of: %s' % ', '.join( + providers.mapped('journal_id.name') + )) + for provider in providers.with_context({'scheduled': True}): + date_since = ( + provider.last_successful_run + ) if provider.last_successful_run else ( + provider.next_run - provider._get_next_run_period() + ) + date_until = provider.next_run + provider._pull(date_since, date_until) + + _logger.info('Scheduled pull of online bank statements complete.') + + @api.multi + def _obtain_statement_data( + self, date_since, date_until + ): + """Hook for extension""" + # Check tests/online_bank_statement_provider_dummy.py for reference + self.ensure_one() + return [] diff --git a/account_bank_statement_import_online/readme/CONFIGURE.rst b/account_bank_statement_import_online/readme/CONFIGURE.rst new file mode 100644 index 00000000..d2ae6f21 --- /dev/null +++ b/account_bank_statement_import_online/readme/CONFIGURE.rst @@ -0,0 +1,23 @@ +To configure online bank statements provider: + +#. Go to *Invoicing > Configuration > Bank Accounts* +#. Open bank account to configure and edit it +#. Set *Bank Feeds* to *Online* +#. Select online bank statements provider in *Online Bank Statements (OCA)* + section +#. Save the bank account +#. Click on provider and configure provider-specific settings. + +or, alternatively: + +#. Go to *Invoicing > Overview* +#. Open settings of the corresponding journal account +#. Switch to *Bank Account* tab +#. Set *Bank Feeds* to *Online* +#. Select online bank statements provider in *Online Bank Statements (OCA)* + section +#. Save the bank account +#. Click on provider and configure provider-specific settings. + +**NOTE**: To access these features, user needs to belong to +*Show Full Accounting Features* group. diff --git a/account_bank_statement_import_online/readme/CONTRIBUTORS.rst b/account_bank_statement_import_online/readme/CONTRIBUTORS.rst new file mode 100644 index 00000000..1c6a35a1 --- /dev/null +++ b/account_bank_statement_import_online/readme/CONTRIBUTORS.rst @@ -0,0 +1 @@ +* Alexey Pelykh diff --git a/account_bank_statement_import_online/readme/DESCRIPTION.rst b/account_bank_statement_import_online/readme/DESCRIPTION.rst new file mode 100644 index 00000000..cc0aaaf4 --- /dev/null +++ b/account_bank_statement_import_online/readme/DESCRIPTION.rst @@ -0,0 +1 @@ +This module provides base for building online bank statements providers. diff --git a/account_bank_statement_import_online/readme/USAGE.rst b/account_bank_statement_import_online/readme/USAGE.rst new file mode 100644 index 00000000..bbc2fcef --- /dev/null +++ b/account_bank_statement_import_online/readme/USAGE.rst @@ -0,0 +1,9 @@ +To pull historical bank statements: + +#. Go to *Invoicing > Configuration > Bank Accounts* +#. Select specific bank accounts +#. Launch *Actions > Online Bank Statements Pull Wizard* +#. Configure date interval and click *Pull* + +**NOTE**: To access these features, user needs to belong to +*Show Full Accounting Features* group. diff --git a/account_bank_statement_import_online/security/ir.model.access.csv b/account_bank_statement_import_online/security/ir.model.access.csv new file mode 100644 index 00000000..4e04821b --- /dev/null +++ b/account_bank_statement_import_online/security/ir.model.access.csv @@ -0,0 +1,3 @@ +id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink +access_online_bank_statement_provider_admin,online.bank.statement.provider:base.group_system,model_online_bank_statement_provider,base.group_system,1,1,1,1 +access_online_bank_statement_provider_user,online.bank.statement.provider:account.group_account_user,model_online_bank_statement_provider,account.group_account_user,1,1,1,1 diff --git a/account_bank_statement_import_online/security/online_bank_statement_provider.xml b/account_bank_statement_import_online/security/online_bank_statement_provider.xml new file mode 100644 index 00000000..521e7e97 --- /dev/null +++ b/account_bank_statement_import_online/security/online_bank_statement_provider.xml @@ -0,0 +1,16 @@ + + + + + + Online Bank Statement Provider multi-company + + + ['|', ('company_id', '=', False), ('company_id', 'child_of', [user.company_id.id])] + + + diff --git a/account_bank_statement_import_online/static/description/icon.png b/account_bank_statement_import_online/static/description/icon.png new file mode 100644 index 0000000000000000000000000000000000000000..3a0328b516c4980e8e44cdb63fd945757ddd132d GIT binary patch literal 9455 zcmW++2RxMjAAjx~&dlBk9S+%}OXg)AGE&Cb*&}d0jUxM@u(PQx^-s)697TX`ehR4?GS^qbkof1cslKgkU)h65qZ9Oc=ml_0temigYLJfnz{IDzUf>bGs4N!v3=Z3jMq&A#7%rM5eQ#dc?k~! zVpnB`o+K7|Al`Q_U;eD$B zfJtP*jH`siUq~{KE)`jP2|#TUEFGRryE2`i0**z#*^6~AI|YzIWy$Cu#CSLW3q=GA z6`?GZymC;dCPk~rBS%eCb`5OLr;RUZ;D`}um=H)BfVIq%7VhiMr)_#G0N#zrNH|__ zc+blN2UAB0=617@>_u;MPHN;P;N#YoE=)R#i$k_`UAA>WWCcEVMh~L_ zj--gtp&|K1#58Yz*AHCTMziU1Jzt_jG0I@qAOHsk$2}yTmVkBp_eHuY$A9)>P6o~I z%aQ?!(GqeQ-Y+b0I(m9pwgi(IIZZzsbMv+9w{PFtd_<_(LA~0H(xz{=FhLB@(1&qHA5EJw1>>=%q2f&^X>IQ{!GJ4e9U z&KlB)z(84HmNgm2hg2C0>WM{E(DdPr+EeU_N@57;PC2&DmGFW_9kP&%?X4}+xWi)( z;)z%wI5>D4a*5XwD)P--sPkoY(a~WBw;E~AW`Yue4kFa^LM3X`8x|}ZUeMnqr}>kH zG%WWW>3ml$Yez?i%)2pbKPI7?5o?hydokgQyZsNEr{a|mLdt;X2TX(#B1j35xPnPW z*bMSSOauW>o;*=kO8ojw91VX!qoOQb)zHJ!odWB}d+*K?#sY_jqPdg{Sm2HdYzdEx zOGVPhVRTGPtv0o}RfVP;Nd(|CB)I;*t&QO8h zFfekr30S!-LHmV_Su-W+rEwYXJ^;6&3|L$mMC8*bQptyOo9;>Qb9Q9`ySe3%V$A*9 zeKEe+b0{#KWGp$F+tga)0RtI)nhMa-K@JS}2krK~n8vJ=Ngm?R!9G<~RyuU0d?nz# z-5EK$o(!F?hmX*2Yt6+coY`6jGbb7tF#6nHA zuKk=GGJ;ZwON1iAfG$E#Y7MnZVmrY|j0eVI(DN_MNFJmyZ|;w4tf@=CCDZ#5N_0K= z$;R~bbk?}TpfDjfB&aiQ$VA}s?P}xPERJG{kxk5~R`iRS(SK5d+Xs9swCozZISbnS zk!)I0>t=A<-^z(cmSFz3=jZ23u13X><0b)P)^1T_))Kr`e!-pb#q&J*Q`p+B6la%C zuVl&0duN<;uOsB3%T9Fp8t{ED108<+W(nOZd?gDnfNBC3>M8WE61$So|P zVvqH0SNtDTcsUdzaMDpT=Ty0pDHHNL@Z0w$Y`XO z2M-_r1S+GaH%pz#Uy0*w$Vdl=X=rQXEzO}d6J^R6zjM1u&c9vYLvLp?W7w(?np9x1 zE_0JSAJCPB%i7p*Wvg)pn5T`8k3-uR?*NT|J`eS#_#54p>!p(mLDvmc-3o0mX*mp_ zN*AeS<>#^-{S%W<*mz^!X$w_2dHWpcJ6^j64qFBft-o}o_Vx80o0>}Du;>kLts;$8 zC`7q$QI(dKYG`Wa8#wl@V4jVWBRGQ@1dr-hstpQL)Tl+aqVpGpbSfN>5i&QMXfiZ> zaA?T1VGe?rpQ@;+pkrVdd{klI&jVS@I5_iz!=UMpTsa~mBga?1r}aRBm1WS;TT*s0f0lY=JBl66Upy)-k4J}lh=P^8(SXk~0xW=T9v*B|gzIhN z>qsO7dFd~mgxAy4V?&)=5ieYq?zi?ZEoj)&2o)RLy=@hbCRcfT5jigwtQGE{L*8<@Yd{zg;CsL5mvzfDY}P-wos_6PfprFVaeqNE%h zKZhLtcQld;ZD+>=nqN~>GvROfueSzJD&BE*}XfU|H&(FssBqY=hPCt`d zH?@s2>I(|;fcW&YM6#V#!kUIP8$Nkdh0A(bEVj``-AAyYgwY~jB zT|I7Bf@%;7aL7Wf4dZ%VqF$eiaC38OV6oy3Z#TER2G+fOCd9Iaoy6aLYbPTN{XRPz z;U!V|vBf%H!}52L2gH_+j;`bTcQRXB+y9onc^wLm5wi3-Be}U>k_u>2Eg$=k!(l@I zcCg+flakT2Nej3i0yn+g+}%NYb?ta;R?(g5SnwsQ49U8Wng8d|{B+lyRcEDvR3+`O{zfmrmvFrL6acVP%yG98X zo&+VBg@px@i)%o?dG(`T;n*$S5*rnyiR#=wW}}GsAcfyQpE|>a{=$Hjg=-*_K;UtD z#z-)AXwSRY?OPefw^iI+ z)AXz#PfEjlwTes|_{sB?4(O@fg0AJ^g8gP}ex9Ucf*@_^J(s_5jJV}c)s$`Myn|Kd z$6>}#q^n{4vN@+Os$m7KV+`}c%4)4pv@06af4-x5#wj!KKb%caK{A&Y#Rfs z-po?Dcb1({W=6FKIUirH&(yg=*6aLCekcKwyfK^JN5{wcA3nhO(o}SK#!CINhI`-I z1)6&n7O&ZmyFMuNwvEic#IiOAwNkR=u5it{B9n2sAJV5pNhar=j5`*N!Na;c7g!l$ z3aYBqUkqqTJ=Re-;)s!EOeij=7SQZ3Hq}ZRds%IM*PtM$wV z@;rlc*NRK7i3y5BETSKuumEN`Xu_8GP1Ri=OKQ$@I^ko8>H6)4rjiG5{VBM>B|%`&&s^)jS|-_95&yc=GqjNo{zFkw%%HHhS~e=s zD#sfS+-?*t|J!+ozP6KvtOl!R)@@-z24}`9{QaVLD^9VCSR2b`b!KC#o;Ki<+wXB6 zx3&O0LOWcg4&rv4QG0)4yb}7BFSEg~=IR5#ZRj8kg}dS7_V&^%#Do==#`u zpy6{ox?jWuR(;pg+f@mT>#HGWHAJRRDDDv~@(IDw&R>9643kK#HN`!1vBJHnC+RM&yIh8{gG2q zA%e*U3|N0XSRa~oX-3EAneep)@{h2vvd3Xvy$7og(sayr@95+e6~Xvi1tUqnIxoIH zVWo*OwYElb#uyW{Imam6f2rGbjR!Y3`#gPqkv57dB6K^wRGxc9B(t|aYDGS=m$&S!NmCtrMMaUg(c zc2qC=2Z`EEFMW-me5B)24AqF*bV5Dr-M5ig(l-WPS%CgaPzs6p_gnCIvTJ=Y<6!gT zVt@AfYCzjjsMEGi=rDQHo0yc;HqoRNnNFeWZgcm?f;cp(6CNylj36DoL(?TS7eU#+ z7&mfr#y))+CJOXQKUMZ7QIdS9@#-}7y2K1{8)cCt0~-X0O!O?Qx#E4Og+;A2SjalQ zs7r?qn0H044=sDN$SRG$arw~n=+T_DNdSrarmu)V6@|?1-ZB#hRn`uilTGPJ@fqEy zGt(f0B+^JDP&f=r{#Y_wi#AVDf-y!RIXU^0jXsFpf>=Ji*TeqSY!H~AMbJdCGLhC) zn7Rx+sXw6uYj;WRYrLd^5IZq@6JI1C^YkgnedZEYy<&4(z%Q$5yv#Boo{AH8n$a zhb4Y3PWdr269&?V%uI$xMcUrMzl=;w<_nm*qr=c3Rl@i5wWB;e-`t7D&c-mcQl7x! zZWB`UGcw=Y2=}~wzrfLx=uet<;m3~=8I~ZRuzvMQUQdr+yTV|ATf1Uuomr__nDf=X zZ3WYJtHp_ri(}SQAPjv+Y+0=fH4krOP@S&=zZ-t1jW1o@}z;xk8 z(Nz1co&El^HK^NrhVHa-_;&88vTU>_J33=%{if;BEY*J#1n59=07jrGQ#IP>@u#3A z;!q+E1Rj3ZJ+!4bq9F8PXJ@yMgZL;>&gYA0%_Kbi8?S=XGM~dnQZQ!yBSgcZhY96H zrWnU;k)qy`rX&&xlDyA%(a1Hhi5CWkmg(`Gb%m(HKi-7Z!LKGRP_B8@`7&hdDy5n= z`OIxqxiVfX@OX1p(mQu>0Ai*v_cTMiw4qRt3~NBvr9oBy0)r>w3p~V0SCm=An6@3n)>@z!|o-$HvDK z|3D2ZMJkLE5loMKl6R^ez@Zz%S$&mbeoqH5`Bb){Ei21q&VP)hWS2tjShfFtGE+$z zzCR$P#uktu+#!w)cX!lWN1XU%K-r=s{|j?)Akf@q#3b#{6cZCuJ~gCxuMXRmI$nGtnH+-h z+GEi!*X=AP<|fG`1>MBdTb?28JYc=fGvAi2I<$B(rs$;eoJCyR6_bc~p!XR@O-+sD z=eH`-ye})I5ic1eL~TDmtfJ|8`0VJ*Yr=hNCd)G1p2MMz4C3^Mj?7;!w|Ly%JqmuW zlIEW^Ft%z?*|fpXda>Jr^1noFZEwFgVV%|*XhH@acv8rdGxeEX{M$(vG{Zw+x(ei@ zmfXb22}8-?Fi`vo-YVrTH*C?a8%M=Hv9MqVH7H^J$KsD?>!SFZ;ZsvnHr_gn=7acz z#W?0eCdVhVMWN12VV^$>WlQ?f;P^{(&pYTops|btm6aj>_Uz+hqpGwB)vWp0Cf5y< zft8-je~nn?W11plq}N)4A{l8I7$!ks_x$PXW-2XaRFswX_BnF{R#6YIwMhAgd5F9X zGmwdadS6(a^fjHtXg8=l?Rc0Sm%hk6E9!5cLVloEy4eh(=FwgP`)~I^5~pBEWo+F6 zSf2ncyMurJN91#cJTy_u8Y}@%!bq1RkGC~-bV@SXRd4F{R-*V`bS+6;W5vZ(&+I<9$;-V|eNfLa5n-6% z2(}&uGRF;p92eS*sE*oR$@pexaqr*meB)VhmIg@h{uzkk$9~qh#cHhw#>O%)b@+(| z^IQgqzuj~Sk(J;swEM-3TrJAPCq9k^^^`q{IItKBRXYe}e0Tdr=Huf7da3$l4PdpwWDop%^}n;dD#K4s#DYA8SHZ z&1!riV4W4R7R#C))JH1~axJ)RYnM$$lIR%6fIVA@zV{XVyx}C+a-Dt8Y9M)^KU0+H zR4IUb2CJ{Hg>CuaXtD50jB(_Tcx=Z$^WYu2u5kubqmwp%drJ6 z?Fo40g!Qd<-l=TQxqHEOuPX0;^z7iX?Ke^a%XT<13TA^5`4Xcw6D@Ur&VT&CUe0d} z1GjOVF1^L@>O)l@?bD~$wzgf(nxX1OGD8fEV?TdJcZc2KoUe|oP1#=$$7ee|xbY)A zDZq+cuTpc(fFdj^=!;{k03C69lMQ(|>uhRfRu%+!k&YOi-3|1QKB z z?n?eq1XP>p-IM$Z^C;2L3itnbJZAip*Zo0aw2bs8@(s^~*8T9go!%dHcAz2lM;`yp zD=7&xjFV$S&5uDaiScyD?B-i1ze`+CoRtz`Wn+Zl&#s4&}MO{@N!ufrzjG$B79)Y2d3tBk&)TxUTw@QS0TEL_?njX|@vq?Uz(nBFK5Pq7*xj#u*R&i|?7+6# z+|r_n#SW&LXhtheZdah{ZVoqwyT{D>MC3nkFF#N)xLi{p7J1jXlmVeb;cP5?e(=f# zuT7fvjSbjS781v?7{)-X3*?>tq?)Yd)~|1{BDS(pqC zC}~H#WXlkUW*H5CDOo<)#x7%RY)A;ShGhI5s*#cRDA8YgqG(HeKDx+#(ZQ?386dv! zlXCO)w91~Vw4AmOcATuV653fa9R$fyK8ul%rG z-wfS zihugoZyr38Im?Zuh6@RcF~t1anQu7>#lPpb#}4cOA!EM11`%f*07RqOVkmX{p~KJ9 z^zP;K#|)$`^Rb{rnHGH{~>1(fawV0*Z#)}M`m8-?ZJV<+e}s9wE# z)l&az?w^5{)`S(%MRzxdNqrs1n*-=jS^_jqE*5XDrA0+VE`5^*p3CuM<&dZEeCjoz zR;uu_H9ZPZV|fQq`Cyw4nscrVwi!fE6ciMmX$!_hN7uF;jjKG)d2@aC4ropY)8etW=xJvni)8eHi`H$%#zn^WJ5NLc-rqk|u&&4Z6fD_m&JfSI1Bvb?b<*n&sfl0^t z=HnmRl`XrFvMKB%9}>PaA`m-fK6a0(8=qPkWS5bb4=v?XcWi&hRY?O5HdulRi4?fN zlsJ*N-0Qw+Yic@s0(2uy%F@ib;GjXt01Fmx5XbRo6+n|pP(&nodMoap^z{~q ziEeaUT@Mxe3vJSfI6?uLND(CNr=#^W<1b}jzW58bIfyWTDle$mmS(|x-0|2UlX+9k zQ^EX7Nw}?EzVoBfT(-LT|=9N@^hcn-_p&sqG z&*oVs2JSU+N4ZD`FhCAWaS;>|wH2G*Id|?pa#@>tyxX`+4HyIArWDvVrX)2WAOQff z0qyHu&-S@i^MS-+j--!pr4fPBj~_8({~e1bfcl0wI1kaoN>mJL6KUPQm5N7lB(ui1 zE-o%kq)&djzWJ}ob<-GfDlkB;F31j-VHKvQUGQ3sp`CwyGJk_i!y^sD0fqC@$9|jO zOqN!r!8-p==F@ZVP=U$qSpY(gQ0)59P1&t@y?5rvg<}E+GB}26NYPp4f2YFQrQtot5mn3wu_qprZ=>Ig-$ zbW26Ws~IgY>}^5w`vTB(G`PTZaDiGBo5o(tp)qli|NeV( z@H_=R8V39rt5J5YB2Ky?4eJJ#b`_iBe2ot~6%7mLt5t8Vwi^Jy7|jWXqa3amOIoRb zOr}WVFP--DsS`1WpN%~)t3R!arKF^Q$e12KEqU36AWwnCBICpH4XCsfnyrHr>$I$4 z!DpKX$OKLWarN7nv@!uIA+~RNO)l$$w}p(;b>mx8pwYvu;dD_unryX_NhT8*Tj>BTrTTL&!?O+%Rv;b?B??gSzdp?6Uug9{ zd@V08Z$BdI?fpoCS$)t4mg4rT8Q_I}h`0d-vYZ^|dOB*Q^S|xqTV*vIg?@fVFSmMpaw0qtTRbx} z({Pg?#{2`sc9)M5N$*N|4;^t$+QP?#mov zGVC@I*lBVrOU-%2y!7%)fAKjpEFsgQc4{amtiHb95KQEwvf<(3T<9-Zm$xIew#P22 zc2Ix|App^>v6(3L_MCU0d3W##AB0M~3D00EWoKZqsJYT(#@w$Y_H7G22M~ApVFTRHMI_3be)Lkn#0F*V8Pq zc}`Cjy$bE;FJ6H7p=0y#R>`}-m4(0F>%@P|?7fx{=R^uFdISRnZ2W_xQhD{YuR3t< z{6yxu=4~JkeA;|(J6_nv#>Nvs&FuLA&PW^he@t(UwFFE8)|a!R{`E`K`i^ZnyE4$k z;(749Ix|oi$c3QbEJ3b~D_kQsPz~fIUKym($a_7dJ?o+40*OLl^{=&oq$<#Q(yyrp z{J-FAniyAw9tPbe&IhQ|a`DqFTVQGQ&Gq3!C2==4x{6EJwiPZ8zub-iXoUtkJiG{} zPaR&}_fn8_z~(=;5lD-aPWD3z8PZS@AaUiomF!G8I}Mf>e~0g#BelA-5#`cj;O5>N Xviia!U7SGha1wx#SCgwmn*{w2TRX*I literal 0 HcmV?d00001 diff --git a/account_bank_statement_import_online/static/description/index.html b/account_bank_statement_import_online/static/description/index.html new file mode 100644 index 00000000..b1890802 --- /dev/null +++ b/account_bank_statement_import_online/static/description/index.html @@ -0,0 +1,460 @@ + + + + + + +Online Bank Statements + + + +
+

Online Bank Statements

+ + +

Beta License: AGPL-3 OCA/bank-statement-import Translate me on Weblate Try me on Runbot

+

This module provides base for building online bank statements providers.

+

Table of contents

+ +
+

Configuration

+

To configure online bank statements provider:

+
    +
  1. Go to Invoicing > Configuration > Bank Accounts
  2. +
  3. Open bank account to configure and edit it
  4. +
  5. Set Bank Feeds to Online
  6. +
  7. Select online bank statements provider in Online Bank Statements (OCA) +section
  8. +
  9. Save the bank account
  10. +
  11. Click on provider and configure provider-specific settings.
  12. +
+

or, alternatively:

+
    +
  1. Go to Invoicing > Overview
  2. +
  3. Open settings of the corresponding journal account
  4. +
  5. Switch to Bank Account tab
  6. +
  7. Set Bank Feeds to Online
  8. +
  9. Select online bank statements provider in Online Bank Statements (OCA) +section
  10. +
  11. Save the bank account
  12. +
  13. Click on provider and configure provider-specific settings.
  14. +
+

NOTE: To access these features, user needs to belong to +Show Full Accounting Features group.

+
+
+

Usage

+

To pull historical bank statements:

+
    +
  1. Go to Invoicing > Configuration > Bank Accounts
  2. +
  3. Select specific bank accounts
  4. +
  5. Launch Actions > Online Bank Statements Pull Wizard
  6. +
  7. Configure date interval and click Pull
  8. +
+

NOTE: To access these features, user needs to belong to +Show Full Accounting Features group.

+
+
+

Bug Tracker

+

Bugs are tracked on GitHub 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.

+

Do not contact contributors directly about support or help with technical issues.

+
+
+

Credits

+
+

Authors

+
    +
  • Brainbean Apps
  • +
  • Dataplug
  • +
+
+ +
+

Maintainers

+

This module is maintained by the OCA.

+Odoo Community Association +

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.

+

This module is part of the OCA/bank-statement-import project on GitHub.

+

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

+
+
+
+ + diff --git a/account_bank_statement_import_online/tests/__init__.py b/account_bank_statement_import_online/tests/__init__.py new file mode 100644 index 00000000..c631b1f0 --- /dev/null +++ b/account_bank_statement_import_online/tests/__init__.py @@ -0,0 +1,3 @@ +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from . import test_account_bank_statement_import_online diff --git a/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py b/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py new file mode 100644 index 00000000..04b96ca1 --- /dev/null +++ b/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py @@ -0,0 +1,55 @@ +# Copyright 2019 Brainbean Apps (https://brainbeanapps.com) +# Copyright 2019 Dataplug (https://dataplug.io) +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). + +from datetime import datetime, timedelta +from dateutil.relativedelta import relativedelta +from random import randrange + +from odoo import models, api + + +class OnlineBankStatementProviderDummy(models.Model): + _inherit = 'online.bank.statement.provider' + + @api.multi + def _obtain_statement_data(self, date_since, date_until): + self.ensure_one() + if self.service != 'dummy': + return super()._obtain_statement_data( + date_since, + date_until, + ) # pragma: no cover + + if self.env.context.get('crash', False): + raise Exception('Expected') + + line_step_options = self.env.context.get('step', { + 'minutes': 5, + }) + line_step = relativedelta(**line_step_options) + expand_by = self.env.context.get('expand_by', 0) + date_since -= expand_by * line_step + date_until += expand_by * line_step + + balance_start = randrange(-10000, 10000, 1) * 0.1 + balance = balance_start + lines = [] + date = date_since + while date < date_until: + amount = randrange(-100, 100, 1) * 0.1 + lines.append({ + 'name': 'payment', + 'amount': amount, + 'date': date, + 'unique_import_id': str(int( + (date - datetime(1970, 1, 1)) / timedelta(seconds=1) + )), + }) + balance += amount + date += line_step + balance_end = balance + return lines, { + 'balance_start': balance_start, + 'balance_end_real': balance_end, + } diff --git a/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py b/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py new file mode 100644 index 00000000..2eb25d19 --- /dev/null +++ b/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py @@ -0,0 +1,343 @@ +# Copyright 2019 Brainbean Apps (https://brainbeanapps.com) +# Copyright 2019 Dataplug (https://dataplug.io) +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from dateutil.relativedelta import relativedelta + +from psycopg2 import IntegrityError + +from odoo.tests import common +from odoo.tools import mute_logger +from odoo import fields + + +class TestAccountBankAccountStatementImportOnline(common.TransactionCase): + + def setUp(self): + super().setUp() + + self.now = fields.Datetime.now() + self.AccountJournal = self.env['account.journal'] + self.OnlineBankStatementProvider = self.env[ + 'online.bank.statement.provider' + ] + self.AccountBankStatement = self.env['account.bank.statement'] + self.AccountBankStatementLine = self.env['account.bank.statement.line'] + + def test_provider_unlink_restricted(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + }) + with common.Form(journal) as journal_form: + journal_form.bank_statements_source = 'online' + journal_form.online_bank_statement_provider = 'dummy' + journal_form.save() + + with self.assertRaises(IntegrityError), mute_logger('odoo.sql_db'): + journal.online_bank_statement_provider_id.unlink() + + def test_cascade_unlink(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + }) + with common.Form(journal) as journal_form: + journal_form.bank_statements_source = 'online' + journal_form.online_bank_statement_provider = 'dummy' + journal_form.save() + + self.assertTrue(journal.online_bank_statement_provider_id) + journal.unlink() + self.assertFalse(self.OnlineBankStatementProvider.search([])) + + def test_source_change_cleanup(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + }) + with common.Form(journal) as journal_form: + journal_form.bank_statements_source = 'online' + journal_form.online_bank_statement_provider = 'dummy' + journal_form.save() + + self.assertTrue(journal.online_bank_statement_provider_id) + + with common.Form(journal) as journal_form: + journal_form.bank_statements_source = 'undefined' + journal_form.save() + + self.assertFalse(journal.online_bank_statement_provider_id) + self.assertFalse(self.OnlineBankStatementProvider.search([])) + + def test_pull_boundary(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + + provider = journal.online_bank_statement_provider_id + provider.active = True + provider.with_context({ + 'expand_by': 1, + })._pull( + self.now - relativedelta(hours=1), + self.now, + ) + + statement = self.AccountBankStatement.search( + [('journal_id', '=', journal.id)], + ) + self.assertEquals(len(statement), 1) + self.assertEquals(len(statement.line_ids), 12) + + def test_pull_mode_daily(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + + provider = journal.online_bank_statement_provider_id + provider.active = True + provider.statement_creation_mode = 'daily' + + provider.with_context(step={'hours': 2})._pull( + self.now - relativedelta(days=1), + self.now, + ) + self.assertEquals( + len(self.AccountBankStatement.search( + [('journal_id', '=', journal.id)] + )), + 2 + ) + + def test_pull_mode_weekly(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + + provider = journal.online_bank_statement_provider_id + provider.active = True + provider.statement_creation_mode = 'weekly' + + provider.with_context(step={'hours': 8})._pull( + self.now - relativedelta(weeks=1), + self.now, + ) + self.assertEquals( + len(self.AccountBankStatement.search( + [('journal_id', '=', journal.id)] + )), + 2 + ) + + def test_pull_mode_monthly(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + + provider = journal.online_bank_statement_provider_id + provider.active = True + provider.statement_creation_mode = 'monthly' + + provider.with_context(step={'hours': 8})._pull( + self.now - relativedelta(months=1), + self.now, + ) + self.assertEquals( + len(self.AccountBankStatement.search( + [('journal_id', '=', journal.id)] + )), + 2 + ) + + def test_pull_scheduled(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + + provider = journal.online_bank_statement_provider_id + provider.active = True + provider.next_run = ( + self.now - relativedelta(days=15) + ) + + self.assertFalse(self.AccountBankStatement.search( + [('journal_id', '=', journal.id)], + )) + + provider.with_context(step={'hours': 8})._scheduled_pull() + + statement = self.AccountBankStatement.search( + [('journal_id', '=', journal.id)], + ) + self.assertEquals(len(statement), 1) + + def test_pull_skip_duplicates_by_unique_import_id(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + + provider = journal.online_bank_statement_provider_id + provider.active = True + provider.statement_creation_mode = 'weekly' + + provider.with_context(step={'hours': 8})._pull( + self.now - relativedelta(weeks=2), + self.now, + ) + self.assertEquals( + len(self.AccountBankStatementLine.search( + [('journal_id', '=', journal.id)] + )), + 14 * (24 / 8) + ) + + provider.with_context(step={'hours': 8})._pull( + self.now - relativedelta(weeks=3), + self.now - relativedelta(weeks=1), + ) + self.assertEquals( + len(self.AccountBankStatementLine.search( + [('journal_id', '=', journal.id)] + )), + 21 * (24 / 8) + ) + + provider.with_context(step={'hours': 8})._pull( + self.now - relativedelta(weeks=1), + self.now, + ) + self.assertEquals( + len(self.AccountBankStatementLine.search( + [('journal_id', '=', journal.id)] + )), + 21 * (24 / 8) + ) + + def test_interval_type_minutes(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + + provider = journal.online_bank_statement_provider_id + provider.active = True + provider.interval_type = 'minutes' + provider._compute_update_schedule() + + def test_interval_type_hours(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + + provider = journal.online_bank_statement_provider_id + provider.active = True + provider.interval_type = 'hours' + provider._compute_update_schedule() + + def test_interval_type_days(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + + provider = journal.online_bank_statement_provider_id + provider.active = True + provider.interval_type = 'days' + provider._compute_update_schedule() + + def test_interval_type_weeks(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + + provider = journal.online_bank_statement_provider_id + provider.active = True + provider.interval_type = 'weeks' + provider._compute_update_schedule() + + def test_pull_no_crash(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + + provider = journal.online_bank_statement_provider_id + provider.active = True + provider.statement_creation_mode = 'weekly' + + provider.with_context( + crash=True, + scheduled=True, + )._pull( + self.now - relativedelta(hours=1), + self.now, + ) + self.assertFalse(self.AccountBankStatement.search( + [('journal_id', '=', journal.id)], + )) + + def test_pull_crash(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + + provider = journal.online_bank_statement_provider_id + provider.active = True + provider.statement_creation_mode = 'weekly' + + with self.assertRaises(Exception): + provider.with_context( + crash=True, + )._pull( + self.now - relativedelta(hours=1), + self.now, + ) diff --git a/account_bank_statement_import_online/views/account_journal.xml b/account_bank_statement_import_online/views/account_journal.xml new file mode 100644 index 00000000..8cb76b52 --- /dev/null +++ b/account_bank_statement_import_online/views/account_journal.xml @@ -0,0 +1,120 @@ + + + + + + account.journal.form + account.journal + + + + + + + + + + + account.journal.form + account.journal + + + + + + + + + + + account.journal.dashboard.kanban + account.journal + + +
+ dashboard.bank_statements_source != 'online_sync' and dashboard.bank_statements_source != 'online' +
+
+
+ + + Online Bank Statements Pull Wizard + ir.actions.server + + + code + + if records: + action = records.action_online_bank_statements_pull_wizard() + + + +
diff --git a/account_bank_statement_import_online/views/online_bank_statement_provider.xml b/account_bank_statement_import_online/views/online_bank_statement_provider.xml new file mode 100644 index 00000000..232ba046 --- /dev/null +++ b/account_bank_statement_import_online/views/online_bank_statement_provider.xml @@ -0,0 +1,96 @@ + + + + + + online.bank.statement.provider.filter + online.bank.statement.provider + + + + + + + + + online.bank.statement.provider.tree + online.bank.statement.provider + + + + + + + + + + + + + + online.bank.statement.provider.form + online.bank.statement.provider + +
+ +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+
+ + +
+
+
+
+ +
diff --git a/account_bank_statement_import_online/wizards/__init__.py b/account_bank_statement_import_online/wizards/__init__.py new file mode 100644 index 00000000..a8ac6626 --- /dev/null +++ b/account_bank_statement_import_online/wizards/__init__.py @@ -0,0 +1,3 @@ +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from . import online_bank_statement_pull_wizard diff --git a/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py b/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py new file mode 100644 index 00000000..6a081e00 --- /dev/null +++ b/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py @@ -0,0 +1,34 @@ +# Copyright 2019 Brainbean Apps (https://brainbeanapps.com) +# Copyright 2019 Dataplug (https://dataplug.io) +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from odoo import fields, models, api + + +class OnlineBankStatementPullWizard(models.TransientModel): + _name = 'online.bank.statement.pull.wizard' + _description = 'Online Bank Statement Pull Wizard' + + date_since = fields.Datetime( + string='Since', + required=True, + default=fields.Datetime.now, + ) + date_until = fields.Datetime( + string='Until', + required=True, + default=fields.Datetime.now, + ) + provider_ids = fields.Many2many( + string='Providers', + comodel_name='online.bank.statement.provider', + column1='wizard_id', + column2='provider_id', + relation='online_bank_statement_provider_pull_wizard_rel' + ) + + @api.multi + def action_pull(self): + self.ensure_one() + self.provider_ids._pull(self.date_since, self.date_until) + return {'type': 'ir.actions.act_window_close'} diff --git a/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.xml b/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.xml new file mode 100644 index 00000000..3fac2b87 --- /dev/null +++ b/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.xml @@ -0,0 +1,32 @@ + + + + + + online.bank.statement.pull.wizard.form + online.bank.statement.pull.wizard + +
+ + + + + + + + + + +
+
+
+
+
+ +
From 81a6106e3120633d3eb1e54f1217061447354068 Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Mon, 23 Mar 2020 08:14:37 +0100 Subject: [PATCH 02/32] [FIX] account_bank_statement_import_online: catch any exception [UPD] Update account_bank_statement_import_online.pot account_bank_statement_import_online 12.0.1.0.1 --- .../__manifest__.py | 2 +- .../account_bank_statement_import_online.pot | 14 +++++++--- .../models/online_bank_statement_provider.py | 10 ++++--- .../online_bank_statement_provider_dummy.py | 10 +++++-- ...st_account_bank_statement_import_online.py | 28 +++++++++++++++++-- 5 files changed, 49 insertions(+), 15 deletions(-) diff --git a/account_bank_statement_import_online/__manifest__.py b/account_bank_statement_import_online/__manifest__.py index c614dd47..4a7ed9a5 100644 --- a/account_bank_statement_import_online/__manifest__.py +++ b/account_bank_statement_import_online/__manifest__.py @@ -4,7 +4,7 @@ { 'name': 'Online Bank Statements', - 'version': '12.0.1.0.0', + 'version': '12.0.1.0.1', 'author': 'Brainbean Apps, ' 'Dataplug, ' diff --git a/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot b/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot index 3d9d353f..3fe107c3 100644 --- a/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot +++ b/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot @@ -14,7 +14,7 @@ msgstr "" "Plural-Forms: \n" #. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:140 +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:141 #, python-format msgid "%(number)s %(type)s" msgstr "" @@ -164,7 +164,7 @@ msgid "If checked, some messages have a delivery error." msgstr "" #. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:137 +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:138 #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_filter #, python-format msgid "Inactive" @@ -239,6 +239,12 @@ msgstr "" msgid "Monthly statements" msgstr "" +#. module: account_bank_statement_import_online +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:191 +#, python-format +msgid "N/A" +msgstr "" + #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__name msgid "Name" @@ -288,14 +294,14 @@ msgid "Online Bank Statement Provider" msgstr "" #. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:182 +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:184 #, python-format msgid "Online Bank Statement Provider \"%s\" failed to obtain statement data since %s until %s:\n" "%s" msgstr "" #. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:191 +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:193 #, python-format msgid "Online Bank Statement Provider failure" msgstr "" diff --git a/account_bank_statement_import_online/models/online_bank_statement_provider.py b/account_bank_statement_import_online/models/online_bank_statement_provider.py index 6efb8343..41001f3a 100644 --- a/account_bank_statement_import_online/models/online_bank_statement_provider.py +++ b/account_bank_statement_import_online/models/online_bank_statement_provider.py @@ -1,10 +1,11 @@ -# Copyright 2019 Brainbean Apps (https://brainbeanapps.com) -# Copyright 2019 Dataplug (https://dataplug.io) +# Copyright 2019-2020 Brainbean Apps (https://brainbeanapps.com) +# Copyright 2019-2020 Dataplug (https://dataplug.io) # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). from dateutil.relativedelta import relativedelta, MO from decimal import Decimal import logging +from sys import exc_info from odoo import models, fields, api, _ from odoo.addons.base.models.res_bank import sanitize_account_number @@ -167,7 +168,8 @@ class OnlineBankStatementProvider(models.Model): statement_date_since, statement_date_until ) - except Exception as e: + except: + e = exc_info()[1] if is_scheduled: _logger.warning( 'Online Bank Statement Provider "%s" failed to' @@ -186,7 +188,7 @@ class OnlineBankStatementProvider(models.Model): provider.name, statement_date_since, statement_date_until, - str(e), + str(e) if e else _('N/A'), ), subject=_( 'Online Bank Statement Provider failure' diff --git a/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py b/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py index 04b96ca1..6c3f0870 100644 --- a/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py +++ b/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py @@ -1,5 +1,5 @@ -# Copyright 2019 Brainbean Apps (https://brainbeanapps.com) -# Copyright 2019 Dataplug (https://dataplug.io) +# Copyright 2019-2020 Brainbean Apps (https://brainbeanapps.com) +# Copyright 2019-2020 Dataplug (https://dataplug.io) # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). from datetime import datetime, timedelta @@ -22,7 +22,11 @@ class OnlineBankStatementProviderDummy(models.Model): ) # pragma: no cover if self.env.context.get('crash', False): - raise Exception('Expected') + exception = self.env.context.get( + 'exception', + Exception('Expected') + ) + raise exception line_step_options = self.env.context.get('step', { 'minutes': 5, diff --git a/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py b/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py index 2eb25d19..00be08f3 100644 --- a/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py +++ b/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py @@ -1,10 +1,10 @@ -# Copyright 2019 Brainbean Apps (https://brainbeanapps.com) -# Copyright 2019 Dataplug (https://dataplug.io) +# Copyright 2019-2020 Brainbean Apps (https://brainbeanapps.com) +# Copyright 2019-2020 Dataplug (https://dataplug.io) # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). from dateutil.relativedelta import relativedelta - from psycopg2 import IntegrityError +from urllib.error import HTTPError from odoo.tests import common from odoo.tools import mute_logger @@ -341,3 +341,25 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): self.now - relativedelta(hours=1), self.now, ) + + def test_pull_httperror(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + + provider = journal.online_bank_statement_provider_id + provider.active = True + provider.statement_creation_mode = 'weekly' + + with self.assertRaises(HTTPError): + provider.with_context( + crash=True, + exception=HTTPError(None, 500, 'Error', None, None), + )._pull( + self.now - relativedelta(hours=1), + self.now, + ) From 108e517818cda2eb0f851d21d26ac40624fec182 Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Sun, 29 Mar 2020 19:25:06 +0200 Subject: [PATCH 03/32] [IMP] account_bank_statement_import_online: hide Create/Import statement account_bank_statement_import_online 12.0.1.1.0 --- .../__manifest__.py | 6 +++--- .../views/account_journal.xml | 14 ++++++++++---- 2 files changed, 13 insertions(+), 7 deletions(-) diff --git a/account_bank_statement_import_online/__manifest__.py b/account_bank_statement_import_online/__manifest__.py index 4a7ed9a5..00142c78 100644 --- a/account_bank_statement_import_online/__manifest__.py +++ b/account_bank_statement_import_online/__manifest__.py @@ -1,10 +1,10 @@ -# Copyright 2019 Brainbean Apps (https://brainbeanapps.com) -# Copyright 2019 Dataplug (https://dataplug.io) +# Copyright 2019-2020 Brainbean Apps (https://brainbeanapps.com) +# Copyright 2019-2020 Dataplug (https://dataplug.io) # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). { 'name': 'Online Bank Statements', - 'version': '12.0.1.0.1', + 'version': '12.0.1.1.0', 'author': 'Brainbean Apps, ' 'Dataplug, ' diff --git a/account_bank_statement_import_online/views/account_journal.xml b/account_bank_statement_import_online/views/account_journal.xml index 8cb76b52..5810dc77 100644 --- a/account_bank_statement_import_online/views/account_journal.xml +++ b/account_bank_statement_import_online/views/account_journal.xml @@ -1,7 +1,7 @@ @@ -94,14 +94,20 @@ - + account.journal.dashboard.kanban account.journal - +
dashboard.bank_statements_source != 'online_sync' and dashboard.bank_statements_source != 'online'
+ + dashboard.bank_statements_source != 'online_sync' and dashboard.bank_statements_source != 'online' + + + dashboard.bank_statements_source != 'online_sync' and dashboard.bank_statements_source != 'online' +
From c6ec3578830759a9e63140622a4add75adf987e8 Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Sat, 11 Apr 2020 06:24:18 +0200 Subject: [PATCH 04/32] [IMP] account_bank_statement_import_online: use pre-computed sanitized bank account number [UPD] Update account_bank_statement_import_online.pot account_bank_statement_import_online 12.0.1.2.0 --- .../__manifest__.py | 2 +- .../account_bank_statement_import_online.pot | 10 +++++----- .../models/online_bank_statement_provider.py | 20 ++++++++++++++++--- .../online_bank_statement_provider_dummy.py | 2 ++ 4 files changed, 25 insertions(+), 9 deletions(-) diff --git a/account_bank_statement_import_online/__manifest__.py b/account_bank_statement_import_online/__manifest__.py index 00142c78..1414cd6d 100644 --- a/account_bank_statement_import_online/__manifest__.py +++ b/account_bank_statement_import_online/__manifest__.py @@ -4,7 +4,7 @@ { 'name': 'Online Bank Statements', - 'version': '12.0.1.1.0', + 'version': '12.0.1.2.0', 'author': 'Brainbean Apps, ' 'Dataplug, ' diff --git a/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot b/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot index 3fe107c3..ccda625a 100644 --- a/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot +++ b/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot @@ -19,11 +19,6 @@ msgstr "" msgid "%(number)s %(type)s" msgstr "" -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__account_number -msgid "Account Number" -msgstr "" - #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction msgid "Action Needed" @@ -372,6 +367,11 @@ msgstr "" msgid "Pull Online Bank Statements" msgstr "" +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__account_number +msgid "Sanitized Account Number" +msgstr "" + #. module: account_bank_statement_import_online #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form msgid "Scheduled Pull" diff --git a/account_bank_statement_import_online/models/online_bank_statement_provider.py b/account_bank_statement_import_online/models/online_bank_statement_provider.py index 41001f3a..30670fdb 100644 --- a/account_bank_statement_import_online/models/online_bank_statement_provider.py +++ b/account_bank_statement_import_online/models/online_bank_statement_provider.py @@ -41,7 +41,7 @@ class OnlineBankStatementProvider(models.Model): related='journal_id.currency_id', ) account_number = fields.Char( - related='journal_id.bank_account_id.acc_number' + related='journal_id.bank_account_id.sanitized_acc_number' ) service = fields.Selection( selection=lambda self: self._selection_service(), @@ -258,6 +258,15 @@ class OnlineBankStatementProvider(models.Model): [('unique_import_id', '=', unique_import_id)], limit=1): continue + bank_account_number = line_values.get('account_number') + if bank_account_number: + line_values.update({ + 'account_number': ( + self._sanitize_bank_account_number( + bank_account_number + ) + ), + }) filtered_lines.append(line_values) statement_values.update({ 'line_ids': [[0, False, line] for line in filtered_lines], @@ -340,11 +349,16 @@ class OnlineBankStatementProvider(models.Model): @api.multi def _generate_unique_import_id(self, unique_import_id): self.ensure_one() - sanitized_account_number = sanitize_account_number(self.account_number) return ( - sanitized_account_number and sanitized_account_number + '-' or '' + self.account_number and self.account_number + '-' or '' ) + str(self.journal_id.id) + '-' + unique_import_id + @api.multi + def _sanitize_bank_account_number(self, bank_account_number): + """Hook for extension""" + self.ensure_one() + return sanitize_account_number(bank_account_number) + @api.multi def _get_next_run_period(self): self.ensure_one() diff --git a/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py b/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py index 6c3f0870..21732b12 100644 --- a/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py +++ b/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py @@ -49,6 +49,8 @@ class OnlineBankStatementProviderDummy(models.Model): 'unique_import_id': str(int( (date - datetime(1970, 1, 1)) / timedelta(seconds=1) )), + 'partner_name': 'John Doe', + 'account_number': 'XX00 0000 0000 0000', }) balance += amount date += line_step From 758c0c84d23734a7baffc19295ca49d74058dc04 Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Sat, 11 Apr 2020 10:21:01 +0200 Subject: [PATCH 05/32] [IMP] account_bank_statement_import_online: allow pull if archived [UPD] Update account_bank_statement_import_online.pot account_bank_statement_import_online 12.0.1.3.0 --- .../__manifest__.py | 2 +- .../account_bank_statement_import_online.pot | 2 +- .../models/account_journal.py | 10 ++- .../models/online_bank_statement_provider.py | 10 +-- .../online_bank_statement_provider_dummy.py | 16 +++-- ...st_account_bank_statement_import_online.py | 64 ++++++++++++++++++- .../views/account_journal.xml | 2 + .../online_bank_statement_pull_wizard.py | 13 ++-- .../online_bank_statement_pull_wizard.xml | 5 +- 9 files changed, 101 insertions(+), 23 deletions(-) diff --git a/account_bank_statement_import_online/__manifest__.py b/account_bank_statement_import_online/__manifest__.py index 1414cd6d..0b717f47 100644 --- a/account_bank_statement_import_online/__manifest__.py +++ b/account_bank_statement_import_online/__manifest__.py @@ -4,7 +4,7 @@ { 'name': 'Online Bank Statements', - 'version': '12.0.1.2.0', + 'version': '12.0.1.3.0', 'author': 'Brainbean Apps, ' 'Dataplug, ' diff --git a/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot b/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot index ccda625a..b02533c6 100644 --- a/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot +++ b/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot @@ -307,7 +307,7 @@ msgid "Online Bank Statement Providers" msgstr "" #. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/account_journal.py:88 +#: code:addons/account_bank_statement_import_online/models/account_journal.py:91 #: model:ir.model,name:account_bank_statement_import_online.model_online_bank_statement_pull_wizard #, python-format msgid "Online Bank Statement Pull Wizard" diff --git a/account_bank_statement_import_online/models/account_journal.py b/account_bank_statement_import_online/models/account_journal.py index cca7974b..9fdc2302 100644 --- a/account_bank_statement_import_online/models/account_journal.py +++ b/account_bank_statement_import_online/models/account_journal.py @@ -1,5 +1,5 @@ -# Copyright 2019 Brainbean Apps (https://brainbeanapps.com) -# Copyright 2019 Dataplug (https://dataplug.io) +# Copyright 2019-2020 Brainbean Apps (https://brainbeanapps.com) +# Copyright 2019-2020 Dataplug (https://dataplug.io) # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). import logging @@ -37,9 +37,12 @@ class AccountJournal(models.Model): @api.model def values_online_bank_statement_provider(self): - return self.env[ + res = self.env[ 'online.bank.statement.provider' ]._get_available_services() + if self.user_has_groups('base.group_no_one'): + res += [('dummy', 'Dummy')] + return res @api.multi def _update_online_bank_statement_provider_id(self): @@ -92,5 +95,6 @@ class AccountJournal(models.Model): 'target': 'new', 'context': { 'default_provider_ids': [(6, False, provider_ids)], + 'active_test': False, }, } diff --git a/account_bank_statement_import_online/models/online_bank_statement_provider.py b/account_bank_statement_import_online/models/online_bank_statement_provider.py index 30670fdb..f5101fe1 100644 --- a/account_bank_statement_import_online/models/online_bank_statement_provider.py +++ b/account_bank_statement_import_online/models/online_bank_statement_provider.py @@ -217,7 +217,9 @@ class OnlineBankStatementProvider(models.Model): 'journal_id': provider.journal_id.id, 'date': statement_date, }) - statement = AccountBankStatement.create( + statement = AccountBankStatement.with_context( + journal_id=provider.journal_id.id, + ).create( # NOTE: This is needed since create() alters values statement_values.copy() ) @@ -275,9 +277,9 @@ class OnlineBankStatementProvider(models.Model): statement_values['balance_start'] = float( statement_values['balance_start'] ) - if 'balance_start' in statement_values: - statement_values['balance_start'] = float( - statement_values['balance_start'] + if 'balance_end_real' in statement_values: + statement_values['balance_end_real'] = float( + statement_values['balance_end_real'] ) statement.write(statement_values) statement_date_since = statement_date_until diff --git a/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py b/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py index 21732b12..d99d5a4c 100644 --- a/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py +++ b/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py @@ -36,7 +36,10 @@ class OnlineBankStatementProviderDummy(models.Model): date_since -= expand_by * line_step date_until += expand_by * line_step - balance_start = randrange(-10000, 10000, 1) * 0.1 + balance_start = self.env.context.get( + 'balance_start', + randrange(-10000, 10000, 1) * 0.1 + ) balance = balance_start lines = [] date = date_since @@ -55,7 +58,10 @@ class OnlineBankStatementProviderDummy(models.Model): balance += amount date += line_step balance_end = balance - return lines, { - 'balance_start': balance_start, - 'balance_end_real': balance_end, - } + statement = {} + if self.env.context.get('balance', True): + statement.update({ + 'balance_start': balance_start, + 'balance_end_real': balance_end, + }) + return lines, statement diff --git a/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py b/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py index 00be08f3..3e5fe738 100644 --- a/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py +++ b/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py @@ -21,6 +21,9 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): self.OnlineBankStatementProvider = self.env[ 'online.bank.statement.provider' ] + self.OnlineBankStatementPullWizard = self.env[ + 'online.bank.statement.pull.wizard' + ] self.AccountBankStatement = self.env['account.bank.statement'] self.AccountBankStatementLine = self.env['account.bank.statement.line'] @@ -84,9 +87,9 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): provider = journal.online_bank_statement_provider_id provider.active = True - provider.with_context({ - 'expand_by': 1, - })._pull( + provider.with_context( + expand_by=1, + )._pull( self.now - relativedelta(hours=1), self.now, ) @@ -363,3 +366,58 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): self.now - relativedelta(hours=1), self.now, ) + + def test_pull_no_balance(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + + provider = journal.online_bank_statement_provider_id + provider.active = True + provider.statement_creation_mode = 'daily' + + provider.with_context( + step={'hours': 2}, + balance_start=0, + balance=False, + )._pull( + self.now - relativedelta(days=1), + self.now, + ) + statements = self.AccountBankStatement.search( + [('journal_id', '=', journal.id)], + order='date asc', + ) + self.assertFalse(statements[0].balance_start) + self.assertFalse(statements[0].balance_end_real) + self.assertTrue(statements[0].balance_end) + self.assertTrue(statements[1].balance_start) + self.assertFalse(statements[1].balance_end_real) + + def test_wizard(self): + journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'dummy', + }) + action = journal.action_online_bank_statements_pull_wizard() + self.assertTrue(action['context']['default_provider_ids'][0][2]) + + wizard = self.OnlineBankStatementPullWizard.with_context( + action['context'] + ).create({ + 'date_since': self.now - relativedelta(hours=1), + 'date_until': self.now, + }) + self.assertTrue(wizard.provider_ids) + + wizard.action_pull() + self.assertTrue(self.AccountBankStatement.search( + [('journal_id', '=', journal.id)], + )) diff --git a/account_bank_statement_import_online/views/account_journal.xml b/account_bank_statement_import_online/views/account_journal.xml index 5810dc77..4b7de788 100644 --- a/account_bank_statement_import_online/views/account_journal.xml +++ b/account_bank_statement_import_online/views/account_journal.xml @@ -31,6 +31,8 @@ attrs="{'required': [('bank_statements_source', '=', 'online')]}" class="oe_edit_only" groups="account.group_account_user" + widget="dynamic_dropdown" + values="values_online_bank_statement_provider" />
-
diff --git a/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py b/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py index 68bff3f7..5a366680 100644 --- a/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py +++ b/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py @@ -2,38 +2,31 @@ # Copyright 2019-2020 Dataplug (https://dataplug.io) # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). -from odoo import fields, models, api +from odoo import api, fields, models class OnlineBankStatementPullWizard(models.TransientModel): - _name = 'online.bank.statement.pull.wizard' - _description = 'Online Bank Statement Pull Wizard' + _name = "online.bank.statement.pull.wizard" + _description = "Online Bank Statement Pull Wizard" date_since = fields.Datetime( - string='Since', - required=True, - default=fields.Datetime.now, + string="Since", required=True, default=fields.Datetime.now, ) date_until = fields.Datetime( - string='Until', - required=True, - default=fields.Datetime.now, + string="Until", required=True, default=fields.Datetime.now, ) provider_ids = fields.Many2many( - string='Providers', - comodel_name='online.bank.statement.provider', - column1='wizard_id', - column2='provider_id', - relation='online_bank_statement_provider_pull_wizard_rel', + string="Providers", + comodel_name="online.bank.statement.provider", + column1="wizard_id", + column2="provider_id", + relation="online_bank_statement_provider_pull_wizard_rel", ) @api.multi def action_pull(self): self.ensure_one() - self.with_context( - active_test=False, - ).provider_ids._pull( - self.date_since, - self.date_until + self.with_context(active_test=False,).provider_ids._pull( + self.date_since, self.date_until ) - return {'type': 'ir.actions.act_window_close'} + return {"type": "ir.actions.act_window_close"} diff --git a/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.xml b/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.xml index 99f71623..8e2bd625 100644 --- a/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.xml +++ b/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.xml @@ -5,29 +5,33 @@ License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). --> - online.bank.statement.pull.wizard.form online.bank.statement.pull.wizard
- + - + - +
-
-
From 9b1fe336577b1242cd017cf6fd5afa2c706ed2b5 Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Sat, 25 Apr 2020 11:24:47 +0200 Subject: [PATCH 14/32] [MIG] account_bank_statement_import_online: Migration to 13.0 --- .../__manifest__.py | 2 +- .../migrations/13.0.1.0.0/noupdate_changes.xml | 13 +++++++++++++ .../migrations/13.0.1.0.0/post-migration.py | 14 ++++++++++++++ .../models/account_journal.py | 3 --- .../models/online_bank_statement_provider.py | 17 +++-------------- .../security/online_bank_statement_provider.xml | 6 +++--- .../online_bank_statement_provider_dummy.py | 3 +-- .../online_bank_statement_pull_wizard.py | 3 +-- 8 files changed, 36 insertions(+), 25 deletions(-) create mode 100644 account_bank_statement_import_online/migrations/13.0.1.0.0/noupdate_changes.xml create mode 100644 account_bank_statement_import_online/migrations/13.0.1.0.0/post-migration.py diff --git a/account_bank_statement_import_online/__manifest__.py b/account_bank_statement_import_online/__manifest__.py index 4f251c08..c8653081 100644 --- a/account_bank_statement_import_online/__manifest__.py +++ b/account_bank_statement_import_online/__manifest__.py @@ -4,7 +4,7 @@ { "name": "Online Bank Statements", - "version": "12.0.1.4.1", + "version": "13.0.1.0.0", "author": "Brainbean Apps, Dataplug, Odoo Community Association (OCA)", "maintainers": ["alexey-pelykh"], "website": "https://github.com/OCA/bank-statement-import/", diff --git a/account_bank_statement_import_online/migrations/13.0.1.0.0/noupdate_changes.xml b/account_bank_statement_import_online/migrations/13.0.1.0.0/noupdate_changes.xml new file mode 100644 index 00000000..55731376 --- /dev/null +++ b/account_bank_statement_import_online/migrations/13.0.1.0.0/noupdate_changes.xml @@ -0,0 +1,13 @@ + + + + + ['|',('company_id','=',False),('company_id','in',company_ids)] + + diff --git a/account_bank_statement_import_online/migrations/13.0.1.0.0/post-migration.py b/account_bank_statement_import_online/migrations/13.0.1.0.0/post-migration.py new file mode 100644 index 00000000..88f5a345 --- /dev/null +++ b/account_bank_statement_import_online/migrations/13.0.1.0.0/post-migration.py @@ -0,0 +1,14 @@ +# Copyright 2020 Brainbean Apps (https://brainbeanapps.com) +# Copyright 2020 Dataplug (https://dataplug.io) +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). + +from openupgradelib import openupgrade # pylint: disable=W7936 + + +@openupgrade.migrate() +def migrate(env, version): + openupgrade.load_data( + env.cr, + "account_bank_statement_import_online", + "migrations/13.0.1.0.0/noupdate_changes.xml", + ) diff --git a/account_bank_statement_import_online/models/account_journal.py b/account_bank_statement_import_online/models/account_journal.py index f0ae857b..53764c25 100644 --- a/account_bank_statement_import_online/models/account_journal.py +++ b/account_bank_statement_import_online/models/account_journal.py @@ -42,7 +42,6 @@ class AccountJournal(models.Model): res += [("dummy", "Dummy")] return res - @api.multi def _update_online_bank_statement_provider_id(self): OnlineBankStatementProvider = self.env["online.bank.statement.provider"] for journal in self.filtered("id"): @@ -72,14 +71,12 @@ class AccountJournal(models.Model): rec._update_online_bank_statement_provider_id() return rec - @api.multi def write(self, vals): res = super().write(vals) if "bank_statements_source" in vals or "online_bank_statement_provider" in vals: self._update_online_bank_statement_provider_id() return res - @api.multi def action_online_bank_statements_pull_wizard(self): provider_ids = self.mapped("online_bank_statement_provider_id").ids return { diff --git a/account_bank_statement_import_online/models/online_bank_statement_provider.py b/account_bank_statement_import_online/models/online_bank_statement_provider.py index 64bf4556..1749d7aa 100644 --- a/account_bank_statement_import_online/models/online_bank_statement_provider.py +++ b/account_bank_statement_import_online/models/online_bank_statement_provider.py @@ -10,7 +10,7 @@ from html import escape from dateutil.relativedelta import MO, relativedelta from pytz import timezone, utc -from odoo import _, api, fields, models +from odoo import SUPERUSER_ID, _, api, fields, models from odoo.addons.base.models.res_bank import sanitize_account_number from odoo.addons.base.models.res_partner import _tz_get @@ -115,7 +115,6 @@ class OnlineBankStatementProvider(models.Model): def values_service(self): return self._get_available_services() - @api.multi @api.depends("service") def _compute_name(self): for provider in self: @@ -123,7 +122,6 @@ class OnlineBankStatementProvider(models.Model): filter(lambda x: x[0] == provider.service, self._selection_service()) )[0][1] - @api.multi @api.depends("active", "interval_type", "interval_number") def _compute_update_schedule(self): for provider in self: @@ -141,8 +139,7 @@ class OnlineBankStatementProvider(models.Model): )[0][1], } - @api.multi # noqa: C901 - def _pull(self, date_since, date_until): + def _pull(self, date_since, date_until): # noqa: C901 AccountBankStatement = self.env["account.bank.statement"] is_scheduled = self.env.context.get("scheduled") if is_scheduled: @@ -255,7 +252,7 @@ class OnlineBankStatementProvider(models.Model): unique_import_id ) line_values.update({"unique_import_id": unique_import_id}) - if AccountBankStatementLine.sudo().search( + if AccountBankStatementLine.with_user(SUPERUSER_ID).search( [("unique_import_id", "=", unique_import_id)], limit=1 ): continue @@ -289,13 +286,11 @@ class OnlineBankStatementProvider(models.Model): if is_scheduled: provider._schedule_next_run() - @api.multi def _schedule_next_run(self): self.ensure_one() self.last_successful_run = self.next_run self.next_run += self._get_next_run_period() - @api.multi def _get_statement_date_since(self, date): self.ensure_one() date = date.replace(hour=0, minute=0, second=0, microsecond=0) @@ -306,7 +301,6 @@ class OnlineBankStatementProvider(models.Model): elif self.statement_creation_mode == "monthly": return date.replace(day=1) - @api.multi def _get_statement_date_step(self): self.ensure_one() if self.statement_creation_mode == "daily": @@ -320,7 +314,6 @@ class OnlineBankStatementProvider(models.Model): months=1, day=1, hour=0, minute=0, second=0, microsecond=0, ) - @api.multi def _get_statement_date(self, date_since, date_until): self.ensure_one() # NOTE: Statement date is treated by Odoo as start of period. Details @@ -330,7 +323,6 @@ class OnlineBankStatementProvider(models.Model): date_since = date_since.replace(tzinfo=utc).astimezone(tz) return date_since.date() - @api.multi def _generate_unique_import_id(self, unique_import_id): self.ensure_one() return ( @@ -340,13 +332,11 @@ class OnlineBankStatementProvider(models.Model): + unique_import_id ) - @api.multi def _sanitize_bank_account_number(self, bank_account_number): """Hook for extension""" self.ensure_one() return sanitize_account_number(bank_account_number) - @api.multi def _get_next_run_period(self): self.ensure_one() if self.interval_type == "minutes": @@ -381,7 +371,6 @@ class OnlineBankStatementProvider(models.Model): _logger.info("Scheduled pull of online bank statements complete.") - @api.multi def _obtain_statement_data(self, date_since, date_until): """Hook for extension""" # Check tests/online_bank_statement_provider_dummy.py for reference diff --git a/account_bank_statement_import_online/security/online_bank_statement_provider.xml b/account_bank_statement_import_online/security/online_bank_statement_provider.xml index c3a4d4e6..0b1ae8e0 100644 --- a/account_bank_statement_import_online/security/online_bank_statement_provider.xml +++ b/account_bank_statement_import_online/security/online_bank_statement_provider.xml @@ -1,8 +1,8 @@ @@ -11,6 +11,6 @@ ['|', ('company_id', '=', False), ('company_id', 'child_of', [user.company_id.id])] + >['|',('company_id','=',False),('company_id','in',company_ids)] diff --git a/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py b/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py index 3ed1137c..a59cac70 100644 --- a/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py +++ b/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py @@ -8,13 +8,12 @@ from random import randrange from dateutil.relativedelta import relativedelta from pytz import timezone -from odoo import api, fields, models +from odoo import fields, models class OnlineBankStatementProviderDummy(models.Model): _inherit = "online.bank.statement.provider" - @api.multi def _obtain_statement_data(self, date_since, date_until): self.ensure_one() if self.service != "dummy": diff --git a/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py b/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py index 5a366680..606a29d0 100644 --- a/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py +++ b/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py @@ -2,7 +2,7 @@ # Copyright 2019-2020 Dataplug (https://dataplug.io) # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). -from odoo import api, fields, models +from odoo import fields, models class OnlineBankStatementPullWizard(models.TransientModel): @@ -23,7 +23,6 @@ class OnlineBankStatementPullWizard(models.TransientModel): relation="online_bank_statement_provider_pull_wizard_rel", ) - @api.multi def action_pull(self): self.ensure_one() self.with_context(active_test=False,).provider_ids._pull( From c0b3ff22faa9e163189f04c991ffb3a957183327 Mon Sep 17 00:00:00 2001 From: oca-travis Date: Sun, 8 Nov 2020 11:10:34 +0000 Subject: [PATCH 15/32] [UPD] Update account_bank_statement_import_online.pot --- .../account_bank_statement_import_online.pot | 73 ++++++++++++------- 1 file changed, 45 insertions(+), 28 deletions(-) diff --git a/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot b/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot index c94aa0cb..54e7742a 100644 --- a/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot +++ b/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot @@ -1,12 +1,12 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: -# * account_bank_statement_import_online +# * account_bank_statement_import_online # msgid "" msgstr "" -"Project-Id-Version: Odoo Server 12.0\n" +"Project-Id-Version: Odoo Server 13.0\n" "Report-Msgid-Bugs-To: \n" -"Last-Translator: <>\n" +"Last-Translator: \n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -14,7 +14,7 @@ msgstr "" "Plural-Forms: \n" #. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:154 +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 #, python-format msgid "%(number)s %(type)s" msgstr "" @@ -97,12 +97,12 @@ msgid "Currency" msgstr "" #. module: account_bank_statement_import_online -#: selection:online.bank.statement.provider,statement_creation_mode:0 +#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__daily msgid "Daily statements" msgstr "" #. module: account_bank_statement_import_online -#: selection:online.bank.statement.provider,interval_type:0 +#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__days msgid "Day(s)" msgstr "" @@ -118,9 +118,11 @@ msgid "Display Name" msgstr "" #. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:197 +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 #, python-format -msgid "Failed to obtain statement data for period since %s until %s: %s. See server logs for more details." +msgid "" +"Failed to obtain statement data for period since %s until %s: %s. See server" +" logs for more details." msgstr "" #. module: account_bank_statement_import_online @@ -139,7 +141,7 @@ msgid "Followers (Partners)" msgstr "" #. module: account_bank_statement_import_online -#: selection:online.bank.statement.provider,interval_type:0 +#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__hours msgid "Hour(s)" msgstr "" @@ -149,23 +151,20 @@ msgstr "" msgid "ID" msgstr "" -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread -msgid "If checked new messages require your attention." -msgstr "" - #. module: account_bank_statement_import_online #: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread msgid "If checked, new messages require your attention." msgstr "" #. module: account_bank_statement_import_online #: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_sms_error msgid "If checked, some messages have a delivery error." msgstr "" #. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:151 +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_filter #, python-format msgid "Inactive" @@ -182,7 +181,7 @@ msgid "Is Follower" msgstr "" #. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:206 +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 #, python-format msgid "Issue with Online Bank Statement Provider" msgstr "" @@ -237,17 +236,17 @@ msgid "Messages" msgstr "" #. module: account_bank_statement_import_online -#: selection:online.bank.statement.provider,interval_type:0 +#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__minutes msgid "Minute(s)" msgstr "" #. module: account_bank_statement_import_online -#: selection:online.bank.statement.provider,statement_creation_mode:0 +#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__monthly msgid "Monthly statements" msgstr "" #. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:204 +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 #, python-format msgid "N/A" msgstr "" @@ -269,7 +268,7 @@ msgstr "" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error_counter -msgid "Number of error" +msgid "Number of errors" msgstr "" #. module: account_bank_statement_import_online @@ -288,13 +287,14 @@ msgid "Number of unread messages" msgstr "" #. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/account_journal.py:29 +#: code:addons/account_bank_statement_import_online/models/account_journal.py:0 #, python-format msgid "Online (OCA)" msgstr "" #. module: account_bank_statement_import_online #: model:ir.model,name:account_bank_statement_import_online.model_online_bank_statement_provider +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_bank_statement_import_journal_creation__online_bank_statement_provider #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_journal__online_bank_statement_provider #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form msgid "Online Bank Statement Provider" @@ -306,7 +306,7 @@ msgid "Online Bank Statement Providers" msgstr "" #. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/account_journal.py:91 +#: code:addons/account_bank_statement_import_online/models/account_journal.py:0 #: model:ir.model,name:account_bank_statement_import_online.model_online_bank_statement_pull_wizard #, python-format msgid "Online Bank Statement Pull Wizard" @@ -324,7 +324,7 @@ msgid "Online Bank Statements Pull Wizard" msgstr "" #. module: account_bank_statement_import_online -#: sql_constraint:online.bank.statement.provider:0 +#: model:ir.model.constraint,message:account_bank_statement_import_online.constraint_online_bank_statement_provider_journal_id_uniq msgid "Only one online banking statement provider per journal!" msgstr "" @@ -366,6 +366,11 @@ msgstr "" msgid "Pull Online Bank Statements" msgstr "" +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_sms_error +msgid "SMS Delivery error" +msgstr "" + #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__account_number msgid "Sanitized Account Number" @@ -382,7 +387,7 @@ msgid "Scheduled update interval" msgstr "" #. module: account_bank_statement_import_online -#: sql_constraint:online.bank.statement.provider:0 +#: model:ir.model.constraint,message:account_bank_statement_import_online.constraint_online_bank_statement_provider_valid_interval_number msgid "Scheduled update interval must be greater than zero!" msgstr "" @@ -396,12 +401,18 @@ msgstr "" msgid "Since" msgstr "" +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Since (at least)" +msgstr "" + #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__statement_creation_mode msgid "Statement Creation Mode" msgstr "" #. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_bank_statement_import_journal_creation__online_bank_statement_provider_id #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_journal__online_bank_statement_provider_id msgid "Statement Provider" msgstr "" @@ -418,7 +429,9 @@ msgstr "" #. module: account_bank_statement_import_online #: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__tz -msgid "Timezone to convert transaction timestamps to prior being saved into a statement." +msgid "" +"Timezone to convert transaction timestamps to prior being saved into a " +"statement." msgstr "" #. module: account_bank_statement_import_online @@ -436,6 +449,11 @@ msgstr "" msgid "Until" msgstr "" +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Until (at least)" +msgstr "" + #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__update_schedule msgid "Update Schedule" @@ -457,12 +475,11 @@ msgid "Website communication history" msgstr "" #. module: account_bank_statement_import_online -#: selection:online.bank.statement.provider,interval_type:0 +#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__weeks msgid "Week(s)" msgstr "" #. module: account_bank_statement_import_online -#: selection:online.bank.statement.provider,statement_creation_mode:0 +#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__weekly msgid "Weekly statements" msgstr "" - From 9c7adb8e7483ffca4cd5b002e309a42d63102651 Mon Sep 17 00:00:00 2001 From: OCA-git-bot Date: Sun, 8 Nov 2020 11:16:13 +0000 Subject: [PATCH 16/32] [UPD] README.rst --- account_bank_statement_import_online/README.rst | 10 +++++----- .../static/description/index.html | 6 +++--- 2 files changed, 8 insertions(+), 8 deletions(-) diff --git a/account_bank_statement_import_online/README.rst b/account_bank_statement_import_online/README.rst index 8951e010..9e69676a 100644 --- a/account_bank_statement_import_online/README.rst +++ b/account_bank_statement_import_online/README.rst @@ -14,13 +14,13 @@ Online Bank Statements :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fbank--statement--import-lightgray.png?logo=github - :target: https://github.com/OCA/bank-statement-import/tree/12.0/account_bank_statement_import_online + :target: https://github.com/OCA/bank-statement-import/tree/13.0/account_bank_statement_import_online :alt: OCA/bank-statement-import .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png - :target: https://translation.odoo-community.org/projects/bank-statement-import-12-0/bank-statement-import-12-0-account_bank_statement_import_online + :target: https://translation.odoo-community.org/projects/bank-statement-import-13-0/bank-statement-import-13-0-account_bank_statement_import_online :alt: Translate me on Weblate .. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png - :target: https://runbot.odoo-community.org/runbot/174/12.0 + :target: https://runbot.odoo-community.org/runbot/174/13.0 :alt: Try me on Runbot |badge1| |badge2| |badge3| |badge4| |badge5| @@ -78,7 +78,7 @@ Bug Tracker Bugs are tracked on `GitHub 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 `_. +`feedback `_. Do not contact contributors directly about support or help with technical issues. @@ -117,6 +117,6 @@ Current `maintainer `__: |maintainer-alexey-pelykh| -This module is part of the `OCA/bank-statement-import `_ project on GitHub. +This module is part of the `OCA/bank-statement-import `_ project on GitHub. You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/account_bank_statement_import_online/static/description/index.html b/account_bank_statement_import_online/static/description/index.html index 70ef39aa..e80ce33e 100644 --- a/account_bank_statement_import_online/static/description/index.html +++ b/account_bank_statement_import_online/static/description/index.html @@ -367,7 +367,7 @@ ul.auto-toc { !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> -

Beta License: AGPL-3 OCA/bank-statement-import Translate me on Weblate Try me on Runbot

+

Beta License: AGPL-3 OCA/bank-statement-import Translate me on Weblate Try me on Runbot

This module provides base for building online bank statements providers.

Table of contents

@@ -426,7 +426,7 @@ section

Bugs are tracked on GitHub 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.

+feedback.

Do not contact contributors directly about support or help with technical issues.

@@ -453,7 +453,7 @@ mission is to support the collaborative development of Odoo features and promote its widespread use.

Current maintainer:

alexey-pelykh

-

This module is part of the OCA/bank-statement-import project on GitHub.

+

This module is part of the OCA/bank-statement-import project on GitHub.

You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

From 24bb324c4603111b943a3ea0e81117bbbec36b2c Mon Sep 17 00:00:00 2001 From: Alexey Pelykh Date: Sun, 8 Nov 2020 15:51:27 +0200 Subject: [PATCH 17/32] [UPD] Brainbean Apps => CorporateHub --- account_bank_statement_import_online/README.rst | 7 ++++--- account_bank_statement_import_online/__manifest__.py | 4 ++-- .../readme/CONTRIBUTORS.rst | 4 +++- 3 files changed, 9 insertions(+), 6 deletions(-) diff --git a/account_bank_statement_import_online/README.rst b/account_bank_statement_import_online/README.rst index 9e69676a..e37468d6 100644 --- a/account_bank_statement_import_online/README.rst +++ b/account_bank_statement_import_online/README.rst @@ -88,13 +88,14 @@ Credits Authors ~~~~~~~ -* Brainbean Apps -* Dataplug +* CorporateHub Contributors ~~~~~~~~~~~~ -* Alexey Pelykh +* `CorporateHub `__ + + * Alexey Pelykh Maintainers ~~~~~~~~~~~ diff --git a/account_bank_statement_import_online/__manifest__.py b/account_bank_statement_import_online/__manifest__.py index c8653081..c45ffa5f 100644 --- a/account_bank_statement_import_online/__manifest__.py +++ b/account_bank_statement_import_online/__manifest__.py @@ -1,11 +1,11 @@ # Copyright 2019-2020 Brainbean Apps (https://brainbeanapps.com) -# Copyright 2019-2020 Dataplug (https://dataplug.io) +# Copyright 2020 CorporateHub (https://corporatehub.eu) # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). { "name": "Online Bank Statements", "version": "13.0.1.0.0", - "author": "Brainbean Apps, Dataplug, Odoo Community Association (OCA)", + "author": "CorporateHub, Odoo Community Association (OCA)", "maintainers": ["alexey-pelykh"], "website": "https://github.com/OCA/bank-statement-import/", "license": "AGPL-3", diff --git a/account_bank_statement_import_online/readme/CONTRIBUTORS.rst b/account_bank_statement_import_online/readme/CONTRIBUTORS.rst index 1c6a35a1..724bc1d0 100644 --- a/account_bank_statement_import_online/readme/CONTRIBUTORS.rst +++ b/account_bank_statement_import_online/readme/CONTRIBUTORS.rst @@ -1 +1,3 @@ -* Alexey Pelykh +* `CorporateHub `__ + + * Alexey Pelykh From 75e726581528b001c0c87039c466a1d6874c9450 Mon Sep 17 00:00:00 2001 From: OCA-git-bot Date: Sun, 8 Nov 2020 14:01:43 +0000 Subject: [PATCH 18/32] [UPD] README.rst --- .../static/description/index.html | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/account_bank_statement_import_online/static/description/index.html b/account_bank_statement_import_online/static/description/index.html index e80ce33e..021525c7 100644 --- a/account_bank_statement_import_online/static/description/index.html +++ b/account_bank_statement_import_online/static/description/index.html @@ -434,14 +434,16 @@ If you spotted it first, help us smashing it by providing a detailed and welcome

Authors

    -
  • Brainbean Apps
  • -
  • Dataplug
  • +
  • CorporateHub
From 5d46a6781afd837ab67de4defb8a9e6c27c8997e Mon Sep 17 00:00:00 2001 From: Bosd Date: Fri, 23 Apr 2021 16:33:18 +0000 Subject: [PATCH 19/32] Added translation using Weblate (Dutch) --- .../i18n/nl.po | 486 ++++++++++++++++++ 1 file changed, 486 insertions(+) create mode 100644 account_bank_statement_import_online/i18n/nl.po diff --git a/account_bank_statement_import_online/i18n/nl.po b/account_bank_statement_import_online/i18n/nl.po new file mode 100644 index 00000000..121e3500 --- /dev/null +++ b/account_bank_statement_import_online/i18n/nl.po @@ -0,0 +1,486 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * account_bank_statement_import_online +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 13.0\n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: Automatically generated\n" +"Language-Team: none\n" +"Language: nl\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: nplurals=2; plural=n != 1;\n" + +#. module: account_bank_statement_import_online +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 +#, python-format +msgid "%(number)s %(type)s" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction +msgid "Action Needed" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__active +msgid "Active" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__api_base +msgid "Api Base" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_attachment_count +msgid "Attachment Count" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Cancel" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate +msgid "Certificate" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_chain +msgid "Certificate Chain" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_private_key +msgid "Certificate Private Key" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_public_key +msgid "Certificate Public Key" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__company_id +msgid "Company" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__company_id +msgid "Company related to this journal" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form +msgid "Configuration" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__create_uid +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__create_uid +msgid "Created by" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__create_date +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__create_date +msgid "Created on" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__currency_id +msgid "Currency" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__daily +msgid "Daily statements" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__days +msgid "Day(s)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form +msgid "Details" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__display_name +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__display_name +msgid "Display Name" +msgstr "" + +#. module: account_bank_statement_import_online +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 +#, python-format +msgid "" +"Failed to obtain statement data for period since %s until %s: %s. See server" +" logs for more details." +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_follower_ids +msgid "Followers" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_channel_ids +msgid "Followers (Channels)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_partner_ids +msgid "Followers (Partners)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__hours +msgid "Hour(s)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__id +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__id +msgid "ID" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread +msgid "If checked, new messages require your attention." +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_sms_error +msgid "If checked, some messages have a delivery error." +msgstr "" + +#. module: account_bank_statement_import_online +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_filter +#, python-format +msgid "Inactive" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__interval_type +msgid "Interval Type" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_is_follower +msgid "Is Follower" +msgstr "" + +#. module: account_bank_statement_import_online +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 +#, python-format +msgid "Issue with Online Bank Statement Provider" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model,name:account_bank_statement_import_online.model_account_journal +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__journal_id +msgid "Journal" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__key +msgid "Key" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider____last_update +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard____last_update +msgid "Last Modified on" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__write_uid +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__write_uid +msgid "Last Updated by" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__write_date +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__write_date +msgid "Last Updated on" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__last_successful_run +msgid "Last successful pull" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_main_attachment_id +msgid "Main Attachment" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error +msgid "Message Delivery error" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_ids +msgid "Messages" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__minutes +msgid "Minute(s)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__monthly +msgid "Monthly statements" +msgstr "" + +#. module: account_bank_statement_import_online +#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 +#, python-format +msgid "N/A" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__name +msgid "Name" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__next_run +msgid "Next scheduled pull" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction_counter +msgid "Number of Actions" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error_counter +msgid "Number of errors" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction_counter +msgid "Number of messages which requires an action" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error_counter +msgid "Number of messages with delivery error" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread_counter +msgid "Number of unread messages" +msgstr "" + +#. module: account_bank_statement_import_online +#: code:addons/account_bank_statement_import_online/models/account_journal.py:0 +#, python-format +msgid "Online (OCA)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model,name:account_bank_statement_import_online.model_online_bank_statement_provider +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_bank_statement_import_journal_creation__online_bank_statement_provider +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_journal__online_bank_statement_provider +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form +msgid "Online Bank Statement Provider" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_filter +msgid "Online Bank Statement Providers" +msgstr "" + +#. module: account_bank_statement_import_online +#: code:addons/account_bank_statement_import_online/models/account_journal.py:0 +#: model:ir.model,name:account_bank_statement_import_online.model_online_bank_statement_pull_wizard +#, python-format +msgid "Online Bank Statement Pull Wizard" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_bank_journal_form +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_journal_form +msgid "Online Bank Statements (OCA)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.actions.server,name:account_bank_statement_import_online.action_online_bank_statements_pull_wizard +msgid "Online Bank Statements Pull Wizard" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.constraint,message:account_bank_statement_import_online.constraint_online_bank_statement_provider_journal_id_uniq +msgid "Only one online banking statement provider per journal!" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__origin +msgid "Origin" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__passphrase +msgid "Passphrase" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__password +msgid "Password" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_bank_journal_form +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_journal_form +msgid "Provider" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__provider_ids +msgid "Providers" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Pull" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.actions.server,name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements_ir_actions_server +#: model:ir.cron,cron_name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements +#: model:ir.cron,name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements +msgid "Pull Online Bank Statements" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_sms_error +msgid "SMS Delivery error" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__account_number +msgid "Sanitized Account Number" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form +msgid "Scheduled Pull" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__interval_number +msgid "Scheduled update interval" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.constraint,message:account_bank_statement_import_online.constraint_online_bank_statement_provider_valid_interval_number +msgid "Scheduled update interval must be greater than zero!" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__service +msgid "Service" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__date_since +msgid "Since" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Since (at least)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__statement_creation_mode +msgid "Statement Creation Mode" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_bank_statement_import_journal_creation__online_bank_statement_provider_id +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_journal__online_bank_statement_provider_id +msgid "Statement Provider" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__currency_id +msgid "The currency used to enter statement" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__tz +msgid "Timezone" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__tz +msgid "" +"Timezone to convert transaction timestamps to prior being saved into a " +"statement." +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread +msgid "Unread Messages" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread_counter +msgid "Unread Messages Counter" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__date_until +msgid "Until" +msgstr "" + +#. module: account_bank_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Until (at least)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__update_schedule +msgid "Update Schedule" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__username +msgid "Username" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__website_message_ids +msgid "Website Messages" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__website_message_ids +msgid "Website communication history" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__weeks +msgid "Week(s)" +msgstr "" + +#. module: account_bank_statement_import_online +#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__weekly +msgid "Weekly statements" +msgstr "" From 89ba13b6653910d17dfb292360dba49e00fb0415 Mon Sep 17 00:00:00 2001 From: Bosd Date: Fri, 23 Apr 2021 16:38:38 +0000 Subject: [PATCH 20/32] Translated using Weblate (Dutch) Currently translated at 92.0% (81 of 88 strings) Translation: bank-statement-import-13.0/bank-statement-import-13.0-account_bank_statement_import_online Translate-URL: https://translation.odoo-community.org/projects/bank-statement-import-13-0/bank-statement-import-13-0-account_bank_statement_import_online/nl/ --- .../i18n/nl.po | 165 +++++++++--------- 1 file changed, 85 insertions(+), 80 deletions(-) diff --git a/account_bank_statement_import_online/i18n/nl.po b/account_bank_statement_import_online/i18n/nl.po index 121e3500..ed187a9f 100644 --- a/account_bank_statement_import_online/i18n/nl.po +++ b/account_bank_statement_import_online/i18n/nl.po @@ -6,49 +6,51 @@ msgid "" msgstr "" "Project-Id-Version: Odoo Server 13.0\n" "Report-Msgid-Bugs-To: \n" -"Last-Translator: Automatically generated\n" +"PO-Revision-Date: 2021-04-23 18:47+0000\n" +"Last-Translator: Bosd \n" "Language-Team: none\n" "Language: nl\n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" "Content-Transfer-Encoding: \n" "Plural-Forms: nplurals=2; plural=n != 1;\n" +"X-Generator: Weblate 4.3.2\n" #. module: account_bank_statement_import_online #: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 #, python-format msgid "%(number)s %(type)s" -msgstr "" +msgstr "%(number)s %(type)s" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction msgid "Action Needed" -msgstr "" +msgstr "Actie vereist" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__active msgid "Active" -msgstr "" +msgstr "Actief" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__api_base msgid "Api Base" -msgstr "" +msgstr "Api Base" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_attachment_count msgid "Attachment Count" -msgstr "" +msgstr "Aantal Bijlagen" #. module: account_bank_statement_import_online #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form msgid "Cancel" -msgstr "" +msgstr "Annuleer" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate msgid "Certificate" -msgstr "" +msgstr "Certificaat" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_chain @@ -58,65 +60,65 @@ msgstr "" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_private_key msgid "Certificate Private Key" -msgstr "" +msgstr "Certificaat privé sleutel" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_public_key msgid "Certificate Public Key" -msgstr "" +msgstr "Certificaat publieke sleutel" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__company_id msgid "Company" -msgstr "" +msgstr "Bedrijf" #. module: account_bank_statement_import_online #: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__company_id msgid "Company related to this journal" -msgstr "" +msgstr "Bedrijf gerelateerd aan dit dagboek" #. module: account_bank_statement_import_online #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form msgid "Configuration" -msgstr "" +msgstr "Configuratie" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__create_uid #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__create_uid msgid "Created by" -msgstr "" +msgstr "Aangemaakt door" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__create_date #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__create_date msgid "Created on" -msgstr "" +msgstr "Aangemaakt op" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__currency_id msgid "Currency" -msgstr "" +msgstr "Valuta" #. module: account_bank_statement_import_online #: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__daily msgid "Daily statements" -msgstr "" +msgstr "Dagelijks afschrift" #. module: account_bank_statement_import_online #: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__days msgid "Day(s)" -msgstr "" +msgstr "Dag(en)" #. module: account_bank_statement_import_online #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form msgid "Details" -msgstr "" +msgstr "Details" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__display_name #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__display_name msgid "Display Name" -msgstr "" +msgstr "Weergavenaam" #. module: account_bank_statement_import_online #: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 @@ -125,147 +127,149 @@ msgid "" "Failed to obtain statement data for period since %s until %s: %s. See server" " logs for more details." msgstr "" +"Kon de afschriften niet verkrijgen voor de periode van %s tot %s:%s. Bekijk " +"de error log van de server voor details." #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_follower_ids msgid "Followers" -msgstr "" +msgstr "Volgers" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_channel_ids msgid "Followers (Channels)" -msgstr "" +msgstr "Volgers (Kanalen)" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_partner_ids msgid "Followers (Partners)" -msgstr "" +msgstr "Volgers (Partners)" #. module: account_bank_statement_import_online #: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__hours msgid "Hour(s)" -msgstr "" +msgstr "Uur/Uren" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__id #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__id msgid "ID" -msgstr "" +msgstr "ID" #. module: account_bank_statement_import_online #: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction #: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread msgid "If checked, new messages require your attention." -msgstr "" +msgstr "Indien aangevinkt, nieuwe berichten vereisen uw aandacht." #. module: account_bank_statement_import_online #: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error #: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_sms_error msgid "If checked, some messages have a delivery error." -msgstr "" +msgstr "Indien aangevinkt, sommige berichten hebben een foutmelding." #. module: account_bank_statement_import_online #: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_filter #, python-format msgid "Inactive" -msgstr "" +msgstr "inactief" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__interval_type msgid "Interval Type" -msgstr "" +msgstr "Interval Type" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_is_follower msgid "Is Follower" -msgstr "" +msgstr "Is volger" #. module: account_bank_statement_import_online #: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 #, python-format msgid "Issue with Online Bank Statement Provider" -msgstr "" +msgstr "Probleem met Online Bank afschrift leverancier" #. module: account_bank_statement_import_online #: model:ir.model,name:account_bank_statement_import_online.model_account_journal #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__journal_id msgid "Journal" -msgstr "" +msgstr "Dagboek" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__key msgid "Key" -msgstr "" +msgstr "Sleutel" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider____last_update #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard____last_update msgid "Last Modified on" -msgstr "" +msgstr "Laatst bijgewerkt op" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__write_uid #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__write_uid msgid "Last Updated by" -msgstr "" +msgstr "Laatst bijgewerkt door" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__write_date #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__write_date msgid "Last Updated on" -msgstr "" +msgstr "Laatst bijgewerkt op" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__last_successful_run msgid "Last successful pull" -msgstr "" +msgstr "Laatst succesvolle opvraag" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_main_attachment_id msgid "Main Attachment" -msgstr "" +msgstr "Hoofdbijlage" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error msgid "Message Delivery error" -msgstr "" +msgstr "Berichtafleverinsfout" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_ids msgid "Messages" -msgstr "" +msgstr "Berichten" #. module: account_bank_statement_import_online #: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__minutes msgid "Minute(s)" -msgstr "" +msgstr "Minuut/Minuten" #. module: account_bank_statement_import_online #: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__monthly msgid "Monthly statements" -msgstr "" +msgstr "Maandelijkse afschriften" #. module: account_bank_statement_import_online #: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 #, python-format msgid "N/A" -msgstr "" +msgstr "N.V.T." #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__name msgid "Name" -msgstr "" +msgstr "Naam" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__next_run msgid "Next scheduled pull" -msgstr "" +msgstr "Volgende geplande opvraag" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction_counter msgid "Number of Actions" -msgstr "" +msgstr "Aantal acties" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error_counter @@ -275,23 +279,23 @@ msgstr "" #. module: account_bank_statement_import_online #: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction_counter msgid "Number of messages which requires an action" -msgstr "" +msgstr "Aantal berichten welke actie vereisen" #. module: account_bank_statement_import_online #: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error_counter msgid "Number of messages with delivery error" -msgstr "" +msgstr "Aantal berichten met afleveringsfouten" #. module: account_bank_statement_import_online #: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread_counter msgid "Number of unread messages" -msgstr "" +msgstr "Aantal ongelezen berichten" #. module: account_bank_statement_import_online #: code:addons/account_bank_statement_import_online/models/account_journal.py:0 #, python-format msgid "Online (OCA)" -msgstr "" +msgstr "Online (OCA)" #. module: account_bank_statement_import_online #: model:ir.model,name:account_bank_statement_import_online.model_online_bank_statement_provider @@ -299,12 +303,12 @@ msgstr "" #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_journal__online_bank_statement_provider #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form msgid "Online Bank Statement Provider" -msgstr "" +msgstr "Online Bank afschrift Aanbieder" #. module: account_bank_statement_import_online #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_filter msgid "Online Bank Statement Providers" -msgstr "" +msgstr "Online Bank afschrift Aanbieders" #. module: account_bank_statement_import_online #: code:addons/account_bank_statement_import_online/models/account_journal.py:0 @@ -317,7 +321,7 @@ msgstr "" #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_bank_journal_form #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_journal_form msgid "Online Bank Statements (OCA)" -msgstr "" +msgstr "Online Bank Afschriften (OCA)" #. module: account_bank_statement_import_online #: model:ir.actions.server,name:account_bank_statement_import_online.action_online_bank_statements_pull_wizard @@ -328,6 +332,7 @@ msgstr "" #: model:ir.model.constraint,message:account_bank_statement_import_online.constraint_online_bank_statement_provider_journal_id_uniq msgid "Only one online banking statement provider per journal!" msgstr "" +"Er kan slechts een bankafschrift leverancier worden ingesteld per rekening!" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__origin @@ -337,35 +342,35 @@ msgstr "" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__passphrase msgid "Passphrase" -msgstr "" +msgstr "wachtwoordzin" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__password msgid "Password" -msgstr "" +msgstr "Wachtwoord" #. module: account_bank_statement_import_online #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_bank_journal_form #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_journal_form msgid "Provider" -msgstr "" +msgstr "Leverancier" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__provider_ids msgid "Providers" -msgstr "" +msgstr "Leveranciers" #. module: account_bank_statement_import_online #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form msgid "Pull" -msgstr "" +msgstr "Opvragen" #. module: account_bank_statement_import_online #: model:ir.actions.server,name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements_ir_actions_server #: model:ir.cron,cron_name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements #: model:ir.cron,name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements msgid "Pull Online Bank Statements" -msgstr "" +msgstr "Online Bank afschrifte opvragen" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_sms_error @@ -375,58 +380,58 @@ msgstr "" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__account_number msgid "Sanitized Account Number" -msgstr "" +msgstr "Opgeschoond rekeningnummer" #. module: account_bank_statement_import_online #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form msgid "Scheduled Pull" -msgstr "" +msgstr "Geplande opvraag" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__interval_number msgid "Scheduled update interval" -msgstr "" +msgstr "Opvraag interval" #. module: account_bank_statement_import_online #: model:ir.model.constraint,message:account_bank_statement_import_online.constraint_online_bank_statement_provider_valid_interval_number msgid "Scheduled update interval must be greater than zero!" -msgstr "" +msgstr "Planningsinterval moet groter zijn dan 0!" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__service msgid "Service" -msgstr "" +msgstr "Service" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__date_since msgid "Since" -msgstr "" +msgstr "sinds" #. module: account_bank_statement_import_online #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form msgid "Since (at least)" -msgstr "" +msgstr "sinds (ten minste)" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__statement_creation_mode msgid "Statement Creation Mode" -msgstr "" +msgstr "Bankafschrift creatie modus" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_bank_statement_import_journal_creation__online_bank_statement_provider_id #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_journal__online_bank_statement_provider_id msgid "Statement Provider" -msgstr "" +msgstr "Afschrift leverancier" #. module: account_bank_statement_import_online #: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__currency_id msgid "The currency used to enter statement" -msgstr "" +msgstr "De valuta voor het gebruikte afschrift" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__tz msgid "Timezone" -msgstr "" +msgstr "Tijdzone" #. module: account_bank_statement_import_online #: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__tz @@ -438,49 +443,49 @@ msgstr "" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread msgid "Unread Messages" -msgstr "" +msgstr "Ongelezen berichten" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread_counter msgid "Unread Messages Counter" -msgstr "" +msgstr "Aantal ongelezen berichten" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__date_until msgid "Until" -msgstr "" +msgstr "Tot" #. module: account_bank_statement_import_online #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form msgid "Until (at least)" -msgstr "" +msgstr "Tot (ten minste)" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__update_schedule msgid "Update Schedule" -msgstr "" +msgstr "Update planning" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__username msgid "Username" -msgstr "" +msgstr "Gebruikersnaam" #. module: account_bank_statement_import_online #: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__website_message_ids msgid "Website Messages" -msgstr "" +msgstr "Website berichten" #. module: account_bank_statement_import_online #: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__website_message_ids msgid "Website communication history" -msgstr "" +msgstr "Website berichten geschiedenis" #. module: account_bank_statement_import_online #: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__weeks msgid "Week(s)" -msgstr "" +msgstr "Weken" #. module: account_bank_statement_import_online #: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__weekly msgid "Weekly statements" -msgstr "" +msgstr "Weekelijkse afschriften" From ee15df8d151127d497b5e211d8380358a5bd9c6e Mon Sep 17 00:00:00 2001 From: Ronald Portier Date: Fri, 28 May 2021 14:26:43 +0200 Subject: [PATCH 21/32] [IMP] account_bank_statement_import_online: black, isort, prettier --- .../__manifest__.py | 2 +- .../models/online_bank_statement_provider.py | 32 +++++-- .../online_bank_statement_provider_dummy.py | 3 +- ...st_account_bank_statement_import_online.py | 83 +++++++++++++------ .../online_bank_statement_pull_wizard.py | 14 ++-- .../account_bank_statement_import_online | 1 + .../setup.py | 6 ++ 7 files changed, 100 insertions(+), 41 deletions(-) create mode 120000 setup/account_bank_statement_import_online/odoo/addons/account_bank_statement_import_online create mode 100644 setup/account_bank_statement_import_online/setup.py diff --git a/account_bank_statement_import_online/__manifest__.py b/account_bank_statement_import_online/__manifest__.py index c45ffa5f..e0de7e07 100644 --- a/account_bank_statement_import_online/__manifest__.py +++ b/account_bank_statement_import_online/__manifest__.py @@ -7,7 +7,7 @@ "version": "13.0.1.0.0", "author": "CorporateHub, Odoo Community Association (OCA)", "maintainers": ["alexey-pelykh"], - "website": "https://github.com/OCA/bank-statement-import/", + "website": "https://github.com/OCA/bank-statement-import", "license": "AGPL-3", "category": "Accounting", "summary": "Online bank statements update", diff --git a/account_bank_statement_import_online/models/online_bank_statement_provider.py b/account_bank_statement_import_online/models/online_bank_statement_provider.py index 1749d7aa..85776a1d 100644 --- a/account_bank_statement_import_online/models/online_bank_statement_provider.py +++ b/account_bank_statement_import_online/models/online_bank_statement_provider.py @@ -47,7 +47,9 @@ class OnlineBankStatementProvider(models.Model): ), ) service = fields.Selection( - selection=lambda self: self._selection_service(), required=True, readonly=True, + selection=lambda self: self._selection_service(), + required=True, + readonly=True, ) interval_type = fields.Selection( selection=[ @@ -60,14 +62,19 @@ class OnlineBankStatementProvider(models.Model): required=True, ) interval_number = fields.Integer( - string="Scheduled update interval", default=1, required=True, + string="Scheduled update interval", + default=1, + required=True, ) update_schedule = fields.Char( - string="Update Schedule", compute="_compute_update_schedule", + string="Update Schedule", + compute="_compute_update_schedule", ) last_successful_run = fields.Datetime(string="Last successful pull") next_run = fields.Datetime( - string="Next scheduled pull", default=fields.Datetime.now, required=True, + string="Next scheduled pull", + default=fields.Datetime.now, + required=True, ) statement_creation_mode = fields.Selection( selection=[ @@ -186,7 +193,8 @@ class OnlineBankStatementProvider(models.Model): break raise statement_date = provider._get_statement_date( - statement_date_since, statement_date_until, + statement_date_since, + statement_date_until, ) if not data: data = ([], {}) @@ -307,11 +315,21 @@ class OnlineBankStatementProvider(models.Model): return relativedelta(days=1, hour=0, minute=0, second=0, microsecond=0) elif self.statement_creation_mode == "weekly": return relativedelta( - weeks=1, weekday=MO, hour=0, minute=0, second=0, microsecond=0, + weeks=1, + weekday=MO, + hour=0, + minute=0, + second=0, + microsecond=0, ) elif self.statement_creation_mode == "monthly": return relativedelta( - months=1, day=1, hour=0, minute=0, second=0, microsecond=0, + months=1, + day=1, + hour=0, + minute=0, + second=0, + microsecond=0, ) def _get_statement_date(self, date_since, date_until): diff --git a/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py b/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py index a59cac70..f2e7b5fb 100644 --- a/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py +++ b/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py @@ -18,7 +18,8 @@ class OnlineBankStatementProviderDummy(models.Model): self.ensure_one() if self.service != "dummy": return super()._obtain_statement_data( - date_since, date_until, + date_since, + date_until, ) # pragma: no cover if self.env.context.get("crash", False): diff --git a/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py b/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py index 5a467275..335b5f70 100644 --- a/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py +++ b/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py @@ -85,7 +85,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): provider.statement_creation_mode = "daily" provider.with_context(step={"hours": 2})._pull( - self.now - relativedelta(days=1), self.now, + self.now - relativedelta(days=1), + self.now, ) self.assertEqual( len(self.AccountBankStatement.search([("journal_id", "=", journal.id)])), 2 @@ -107,7 +108,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): provider.statement_creation_mode = "weekly" provider.with_context(step={"hours": 8})._pull( - self.now - relativedelta(weeks=1), self.now, + self.now - relativedelta(weeks=1), + self.now, ) self.assertEqual( len(self.AccountBankStatement.search([("journal_id", "=", journal.id)])), 2 @@ -129,7 +131,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): provider.statement_creation_mode = "monthly" provider.with_context(step={"hours": 8})._pull( - self.now - relativedelta(months=1), self.now, + self.now - relativedelta(months=1), + self.now, ) self.assertEqual( len(self.AccountBankStatement.search([("journal_id", "=", journal.id)])), 2 @@ -179,7 +182,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): data_since=self.now - relativedelta(weeks=2), data_until=self.now, )._pull( - self.now - relativedelta(weeks=2), self.now, + self.now - relativedelta(weeks=2), + self.now, ) self.assertEqual( len( @@ -193,7 +197,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): data_since=self.now - relativedelta(weeks=3), data_until=self.now - relativedelta(weeks=1), )._pull( - self.now - relativedelta(weeks=3), self.now - relativedelta(weeks=1), + self.now - relativedelta(weeks=3), + self.now - relativedelta(weeks=1), ) self.assertEqual( len( @@ -207,7 +212,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): data_since=self.now - relativedelta(weeks=1), data_until=self.now, )._pull( - self.now - relativedelta(weeks=1), self.now, + self.now - relativedelta(weeks=1), + self.now, ) self.assertEqual( len( @@ -296,7 +302,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): provider.statement_creation_mode = "weekly" provider.with_context(crash=True, scheduled=True)._pull( - self.now - relativedelta(hours=1), self.now, + self.now - relativedelta(hours=1), + self.now, ) self.assertFalse( self.AccountBankStatement.search([("journal_id", "=", journal.id)]) @@ -319,7 +326,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): with self.assertRaises(Exception): provider.with_context(crash=True)._pull( - self.now - relativedelta(hours=1), self.now, + self.now - relativedelta(hours=1), + self.now, ) def test_pull_httperror(self): @@ -339,9 +347,11 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): with self.assertRaises(HTTPError): provider.with_context( - crash=True, exception=HTTPError(None, 500, "Error", None, None), + crash=True, + exception=HTTPError(None, 500, "Error", None, None), )._pull( - self.now - relativedelta(hours=1), self.now, + self.now - relativedelta(hours=1), + self.now, ) def test_pull_no_balance(self): @@ -360,12 +370,17 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): provider.statement_creation_mode = "daily" provider.with_context( - step={"hours": 2}, balance_start=0, amount=100.0, balance=False, + step={"hours": 2}, + balance_start=0, + amount=100.0, + balance=False, )._pull( - self.now - relativedelta(days=1), self.now, + self.now - relativedelta(days=1), + self.now, ) statements = self.AccountBankStatement.search( - [("journal_id", "=", journal.id)], order="date asc", + [("journal_id", "=", journal.id)], + order="date asc", ) self.assertFalse(statements[0].balance_start) self.assertFalse(statements[0].balance_end_real) @@ -421,24 +436,30 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): } provider.with_context( - **provider_context, data_until=datetime(2020, 1, 31), + **provider_context, + data_until=datetime(2020, 1, 31), )._pull( - datetime(2020, 1, 1), datetime(2020, 1, 31), + datetime(2020, 1, 1), + datetime(2020, 1, 31), ) statements = self.AccountBankStatement.search( - [("journal_id", "=", journal.id)], order="date asc", + [("journal_id", "=", journal.id)], + order="date asc", ) self.assertEqual(len(statements), 1) self.assertEqual(statements[0].balance_start, 0.0) self.assertEqual(statements[0].balance_end_real, 30.0) provider.with_context( - **provider_context, data_until=datetime(2020, 2, 15), + **provider_context, + data_until=datetime(2020, 2, 15), )._pull( - datetime(2020, 1, 1), datetime(2020, 2, 29), + datetime(2020, 1, 1), + datetime(2020, 2, 29), ) statements = self.AccountBankStatement.search( - [("journal_id", "=", journal.id)], order="date asc", + [("journal_id", "=", journal.id)], + order="date asc", ) self.assertEqual(len(statements), 2) self.assertEqual(statements[0].balance_start, 0.0) @@ -447,12 +468,15 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): self.assertEqual(statements[1].balance_end_real, 45.0) provider.with_context( - **provider_context, data_until=datetime(2020, 2, 29), + **provider_context, + data_until=datetime(2020, 2, 29), )._pull( - datetime(2020, 1, 1), datetime(2020, 2, 29), + datetime(2020, 1, 1), + datetime(2020, 2, 29), ) statements = self.AccountBankStatement.search( - [("journal_id", "=", journal.id)], order="date asc", + [("journal_id", "=", journal.id)], + order="date asc", ) self.assertEqual(len(statements), 2) self.assertEqual(statements[0].balance_start, 0.0) @@ -480,7 +504,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): data_until=datetime(2020, 4, 18, 2, 0), tz="UTC", )._pull( - datetime(2020, 4, 17, 22, 0), datetime(2020, 4, 18, 2, 0), + datetime(2020, 4, 17, 22, 0), + datetime(2020, 4, 18, 2, 0), ) statement = self.AccountBankStatement.search([("journal_id", "=", journal.id)]) @@ -513,7 +538,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): data_until=datetime(2020, 4, 18, 2, 0), tz="UTC", )._pull( - datetime(2020, 4, 17, 22, 0), datetime(2020, 4, 18, 2, 0), + datetime(2020, 4, 17, 22, 0), + datetime(2020, 4, 18, 2, 0), ) statement = self.AccountBankStatement.search([("journal_id", "=", journal.id)]) @@ -545,7 +571,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): data_since=datetime(2020, 4, 18, 0, 0), data_until=datetime(2020, 4, 18, 4, 0), )._pull( - datetime(2020, 4, 17, 22, 0), datetime(2020, 4, 18, 2, 0), + datetime(2020, 4, 17, 22, 0), + datetime(2020, 4, 18, 2, 0), ) statement = self.AccountBankStatement.search([("journal_id", "=", journal.id)]) @@ -572,7 +599,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): provider = journal.online_bank_statement_provider_id provider.active = True provider.with_context(step={"hours": 1}, timestamp_mode="date")._pull( - datetime(2020, 4, 18, 0, 0), datetime(2020, 4, 18, 4, 0), + datetime(2020, 4, 18, 0, 0), + datetime(2020, 4, 18, 4, 0), ) statement = self.AccountBankStatement.search([("journal_id", "=", journal.id)]) @@ -602,7 +630,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): data_until=datetime(2020, 4, 18, 4, 0), timestamp_mode="str", )._pull( - datetime(2020, 4, 18, 0, 0), datetime(2020, 4, 18, 4, 0), + datetime(2020, 4, 18, 0, 0), + datetime(2020, 4, 18, 4, 0), ) statement = self.AccountBankStatement.search([("journal_id", "=", journal.id)]) diff --git a/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py b/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py index 606a29d0..52225668 100644 --- a/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py +++ b/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py @@ -10,10 +10,14 @@ class OnlineBankStatementPullWizard(models.TransientModel): _description = "Online Bank Statement Pull Wizard" date_since = fields.Datetime( - string="Since", required=True, default=fields.Datetime.now, + string="Since", + required=True, + default=fields.Datetime.now, ) date_until = fields.Datetime( - string="Until", required=True, default=fields.Datetime.now, + string="Until", + required=True, + default=fields.Datetime.now, ) provider_ids = fields.Many2many( string="Providers", @@ -25,7 +29,7 @@ class OnlineBankStatementPullWizard(models.TransientModel): def action_pull(self): self.ensure_one() - self.with_context(active_test=False,).provider_ids._pull( - self.date_since, self.date_until - ) + self.with_context( + active_test=False, + ).provider_ids._pull(self.date_since, self.date_until) return {"type": "ir.actions.act_window_close"} diff --git a/setup/account_bank_statement_import_online/odoo/addons/account_bank_statement_import_online b/setup/account_bank_statement_import_online/odoo/addons/account_bank_statement_import_online new file mode 120000 index 00000000..b31ca33c --- /dev/null +++ b/setup/account_bank_statement_import_online/odoo/addons/account_bank_statement_import_online @@ -0,0 +1 @@ +../../../../account_bank_statement_import_online \ No newline at end of file diff --git a/setup/account_bank_statement_import_online/setup.py b/setup/account_bank_statement_import_online/setup.py new file mode 100644 index 00000000..28c57bb6 --- /dev/null +++ b/setup/account_bank_statement_import_online/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) From 541b1c227dfb046a1cfdbc99f183ea184c0d021c Mon Sep 17 00:00:00 2001 From: Florent de Labarre Date: Thu, 16 Apr 2020 17:53:08 +0200 Subject: [PATCH 22/32] [ADD] account_bank_statement_import_online_ponto --- .../README.rst | 102 ++++++++ .../__init__.py | 4 + .../__manifest__.py | 15 ++ .../models/__init__.py | 4 + .../online_bank_statement_provider_ponto.py | 229 ++++++++++++++++++ .../static/description/icon.png | Bin 0 -> 9455 bytes .../tests/__init__.py | 3 + ...ount_bank_statement_import_online_ponto.py | 128 ++++++++++ .../view/online_bank_statement_provider.xml | 19 ++ 9 files changed, 504 insertions(+) create mode 100644 account_bank_statement_import_online_ponto/README.rst create mode 100644 account_bank_statement_import_online_ponto/__init__.py create mode 100644 account_bank_statement_import_online_ponto/__manifest__.py create mode 100644 account_bank_statement_import_online_ponto/models/__init__.py create mode 100644 account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py create mode 100644 account_bank_statement_import_online_ponto/static/description/icon.png create mode 100644 account_bank_statement_import_online_ponto/tests/__init__.py create mode 100644 account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py create mode 100644 account_bank_statement_import_online_ponto/view/online_bank_statement_provider.xml diff --git a/account_bank_statement_import_online_ponto/README.rst b/account_bank_statement_import_online_ponto/README.rst new file mode 100644 index 00000000..8439d25d --- /dev/null +++ b/account_bank_statement_import_online_ponto/README.rst @@ -0,0 +1,102 @@ +=============================== +Online Bank Statements: MyPonto +=============================== + +.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png + :target: https://odoo-community.org/page/development-status + :alt: Beta +.. |badge2| image:: https://img.shields.io/badge/licence-AGPL--3-blue.png + :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html + :alt: License: AGPL-3 +.. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fbank--statement--import-lightgray.png?logo=github + :target: https://github.com/OCA/bank-statement-import/tree/12.0/account_bank_statement_import_online_ponto + :alt: OCA/bank-statement-import +.. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png + :target: https://translation.odoo-community.org/projects/bank-statement-import-12-0/bank-statement-import-12-0-account_bank_statement_import_online_ponto + :alt: Translate me on Weblate +.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png + :target: https://runbot.odoo-community.org/runbot/174/12.0 + :alt: Try me on Runbot + +|badge1| |badge2| |badge3| |badge4| |badge5| + +This module provides online bank statements from MyPonto.com. +MyPonto + +**Table of contents** + +.. contents:: + :local: + +Configuration +============= + +To configure online bank statements provider: + +#. Go to *Invoicing > Configuration > Bank Accounts* +#. Open bank account to configure and edit it +#. Set *Bank Feeds* to *Online* +#. Select *MyPonto.com* as online bank statements provider in + *Online Bank Statements (OCA)* section +#. Save the bank account +#. Click on provider and configure provider-specific settings. + +or, alternatively: + +#. Go to *Invoicing > Overview* +#. Open settings of the corresponding journal account +#. Switch to *Bank Account* tab +#. Set *Bank Feeds* to *Online* +#. Select *Qonto.eu* as online bank statements provider in + *Online Bank Statements (OCA)* section +#. Save the bank account +#. Click on provider and configure provider-specific settings. + +To obtain *Login* and *Key*: + +#. Open `MyPonto.com `_. + +Usage +===== + +To pull historical bank statements: + +#. Go to *Invoicing > Configuration > Bank Accounts* +#. Select specific bank accounts +#. Launch *Actions > Online Bank Statements Pull Wizard* +#. Configure date interval and click *Pull* + +Bug Tracker +=========== + +Bugs are tracked on `GitHub 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 `_. + +Do not contact contributors directly about support or help with technical issues. + +Credits +======= + +Authors +~~~~~~~ + +* Florent de Labarre + +Maintainers +~~~~~~~~~~~ + +This module is maintained by the OCA. + +.. image:: https://odoo-community.org/logo.png + :alt: Odoo Community Association + :target: https://odoo-community.org + +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. + +This module is part of the `OCA/bank-statement-import `_ project on GitHub. + +You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/account_bank_statement_import_online_ponto/__init__.py b/account_bank_statement_import_online_ponto/__init__.py new file mode 100644 index 00000000..de73a3e3 --- /dev/null +++ b/account_bank_statement_import_online_ponto/__init__.py @@ -0,0 +1,4 @@ +# Copyright 2020 Florent de Labarre +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from . import models diff --git a/account_bank_statement_import_online_ponto/__manifest__.py b/account_bank_statement_import_online_ponto/__manifest__.py new file mode 100644 index 00000000..a709649e --- /dev/null +++ b/account_bank_statement_import_online_ponto/__manifest__.py @@ -0,0 +1,15 @@ +# Copyright 2020 Florent de Labarre +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). +{ + "name": "Online Bank Statements: MyPonto.com", + "version": "12.0.1.0.0", + "category": "Account", + "website": "https://github.com/OCA/bank-statement-import", + "author": "Florent de Labarre, Odoo Community Association (OCA)", + "license": "AGPL-3", + "installable": True, + "depends": ["account_bank_statement_import_online"], + "data": [ + "view/online_bank_statement_provider.xml" + ], +} diff --git a/account_bank_statement_import_online_ponto/models/__init__.py b/account_bank_statement_import_online_ponto/models/__init__.py new file mode 100644 index 00000000..cc57537b --- /dev/null +++ b/account_bank_statement_import_online_ponto/models/__init__.py @@ -0,0 +1,4 @@ +# Copyright 2020 Florent de Labarre +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from . import online_bank_statement_provider_ponto diff --git a/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py b/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py new file mode 100644 index 00000000..2d05fcdd --- /dev/null +++ b/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py @@ -0,0 +1,229 @@ +# Copyright 2020 Florent de Labarre +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +import requests +import json +import base64 +import time +import pytz +import re +from datetime import datetime + +from odoo import api, fields, models, _ +from odoo.exceptions import UserError +from dateutil.relativedelta import relativedelta +from odoo.addons.base.models.res_bank import sanitize_account_number + +PONTO_ENDPOINT = 'https://api.myponto.com' + + +class OnlineBankStatementProviderPonto(models.Model): + _inherit = 'online.bank.statement.provider' + + ponto_token = fields.Char(readonly=True) + ponto_token_expiration = fields.Datetime(readonly=True) + ponto_last_identifier = fields.Char(readonly=True) + + def ponto_reset_last_identifier(self): + self.write({'ponto_last_identifier': False}) + + @api.model + def _get_available_services(self): + return super()._get_available_services() + [ + ('ponto', 'MyPonto.com'), + ] + + def _obtain_statement_data(self, date_since, date_until): + self.ensure_one() + if self.service != 'ponto': + return super()._obtain_statement_data( + date_since, + date_until, + ) + return self._ponto_obtain_statement_data(date_since, date_until) + + def _get_statement_date(self, date_since, date_until): + self.ensure_one() + if self.service != 'ponto': + return super()._get_statement_date( + date_since, + date_until, + ) + return date_since.astimezone(pytz.timezone('Europe/Paris')).date() + + ######### + # ponto # + ######### + + def _ponto_header_token(self): + self.ensure_one() + if self.username and self.password: + login = '%s:%s' % (self.username, self.password) + login = base64.b64encode(login.encode('UTF-8')).decode('UTF-8') + return {'Content-Type': 'application/x-www-form-urlencoded', + 'Accept': 'application/json', + 'Authorization': 'Basic %s' % login, } + raise UserError(_('Please fill login and key.')) + + def _ponto_header(self): + self.ensure_one() + if not self.ponto_token \ + or not self.ponto_token_expiration \ + or self.ponto_token_expiration <= fields.Datetime.now(): + + url = PONTO_ENDPOINT + '/oauth2/token' + response = requests.post(url, verify=False, + params={'grant_type': 'client_credentials'}, + headers=self._ponto_header_token()) + if response.status_code == 200: + data = json.loads(response.text) + access_token = data.get('access_token', False) + if not access_token: + raise UserError(_('Ponto : no token')) + else: + self.sudo().ponto_token = access_token + expiration_date = fields.Datetime.now() + relativedelta( + seconds=data.get('expires_in', False)) + self.sudo().ponto_token_expiration = expiration_date + else: + raise UserError(_('%s \n\n %s') % (response.status_code, response.text)) + return {'Accept': 'application/json', + 'Authorization': 'Bearer %s' % self.ponto_token, } + + def _ponto_get_account_ids(self): + url = PONTO_ENDPOINT + '/accounts' + response = requests.get(url, verify=False, params={'limit': 100}, + headers=self._ponto_header()) + if response.status_code == 200: + data = json.loads(response.text) + res = {} + for account in data.get('data', []): + iban = sanitize_account_number( + account.get('attributes', {}).get('reference', '')) + res[iban] = account.get('id') + return res + raise UserError(_('%s \n\n %s') % (response.status_code, response.text)) + + def _ponto_synchronisation(self, account_id): + url = PONTO_ENDPOINT + '/synchronizations' + data = {'data': { + 'type': 'synchronization', + 'attributes': { + 'resourceType': 'account', + 'resourceId': account_id, + 'subtype': 'accountTransactions' + } + }} + response = requests.post(url, verify=False, + headers=self._ponto_header(), + json=data) + if response.status_code in (200, 201, 400): + data = json.loads(response.text) + sync_id = data.get('attributes', {}).get('resourceId', False) + else: + raise UserError(_('Error during Create Synchronisation %s \n\n %s') % ( + response.status_code, response.text)) + + # Check synchronisation + if not sync_id: + return + url = PONTO_ENDPOINT + '/synchronizations/' + sync_id + number = 0 + while number == 100: + number += 1 + response = requests.get(url, verify=False, headers=self._ponto_header()) + if response.status_code == 200: + data = json.loads(response.text) + status = data.get('status', {}) + if status in ('success', 'error'): + return + time.sleep(4) + + def _ponto_get_transaction(self, account_id, date_since, date_until): + page_url = PONTO_ENDPOINT + '/accounts/' + account_id + '/transactions' + params = {'limit': 100} + page_next = True + last_identifier = self.ponto_last_identifier + if last_identifier: + params['before'] = last_identifier + page_next = False + transaction_lines = [] + latest_identifier = False + while page_url: + response = requests.get(page_url, verify=False, params=params, + headers=self._ponto_header()) + if response.status_code == 200: + if params.get('before'): + params.pop('before') + data = json.loads(response.text) + links = data.get('links', {}) + if page_next: + page_url = links.get('next', False) + else: + page_url = links.get('prev', False) + transactions = data.get('data', []) + if transactions: + current_transactions = [] + for transaction in transactions: + date = self._ponto_date_from_string( + transaction.get('attributes', {}).get('executionDate')) + if date_since <= date < date_until: + current_transactions.append(transaction) + + if current_transactions: + if not page_next or (page_next and not latest_identifier): + latest_identifier = current_transactions[0].get('id') + transaction_lines.extend(current_transactions) + else: + raise UserError( + _('Error during get transaction.\n\n%s \n\n %s') % ( + response.status_code, response.text)) + if latest_identifier: + self.ponto_last_identifier = latest_identifier + return transaction_lines + + def _ponto_date_from_string(self, date_str): + return datetime.strptime(date_str, '%Y-%m-%dT%H:%M:%S.%fZ') + + def _ponto_obtain_statement_data(self, date_since, date_until): + self.ensure_one() + + account_ids = self._ponto_get_account_ids() + journal = self.journal_id + + iban = self.account_number + account_id = account_ids.get(iban) + if not account_id: + raise UserError( + _('Ponto : wrong configuration, unknow account %s') + % journal.bank_account_id.acc_number) + + self._ponto_synchronisation(account_id) + + transaction_lines = self._ponto_get_transaction(account_id, + date_since, + date_until) + + new_transactions = [] + sequence = 0 + for transaction in transaction_lines: + sequence += 1 + attributes = transaction.get('attributes', {}) + ref = '%s %s' % ( + attributes.get('description'), + attributes.get('counterpartName')) + date = self._ponto_date_from_string(attributes.get('executionDate')) + + vals_line = { + 'sequence': sequence, + 'date': date, + 'name': re.sub(' +', ' ', ref) or '/', + 'ref': attributes.get('remittanceInformation', ''), + 'unique_import_id': transaction['id'], + 'amount': attributes['amount'], + } + new_transactions.append(vals_line) + + if new_transactions: + return new_transactions, {} + return diff --git a/account_bank_statement_import_online_ponto/static/description/icon.png b/account_bank_statement_import_online_ponto/static/description/icon.png new file mode 100644 index 0000000000000000000000000000000000000000..3a0328b516c4980e8e44cdb63fd945757ddd132d GIT binary patch literal 9455 zcmW++2RxMjAAjx~&dlBk9S+%}OXg)AGE&Cb*&}d0jUxM@u(PQx^-s)697TX`ehR4?GS^qbkof1cslKgkU)h65qZ9Oc=ml_0temigYLJfnz{IDzUf>bGs4N!v3=Z3jMq&A#7%rM5eQ#dc?k~! zVpnB`o+K7|Al`Q_U;eD$B zfJtP*jH`siUq~{KE)`jP2|#TUEFGRryE2`i0**z#*^6~AI|YzIWy$Cu#CSLW3q=GA z6`?GZymC;dCPk~rBS%eCb`5OLr;RUZ;D`}um=H)BfVIq%7VhiMr)_#G0N#zrNH|__ zc+blN2UAB0=617@>_u;MPHN;P;N#YoE=)R#i$k_`UAA>WWCcEVMh~L_ zj--gtp&|K1#58Yz*AHCTMziU1Jzt_jG0I@qAOHsk$2}yTmVkBp_eHuY$A9)>P6o~I z%aQ?!(GqeQ-Y+b0I(m9pwgi(IIZZzsbMv+9w{PFtd_<_(LA~0H(xz{=FhLB@(1&qHA5EJw1>>=%q2f&^X>IQ{!GJ4e9U z&KlB)z(84HmNgm2hg2C0>WM{E(DdPr+EeU_N@57;PC2&DmGFW_9kP&%?X4}+xWi)( z;)z%wI5>D4a*5XwD)P--sPkoY(a~WBw;E~AW`Yue4kFa^LM3X`8x|}ZUeMnqr}>kH zG%WWW>3ml$Yez?i%)2pbKPI7?5o?hydokgQyZsNEr{a|mLdt;X2TX(#B1j35xPnPW z*bMSSOauW>o;*=kO8ojw91VX!qoOQb)zHJ!odWB}d+*K?#sY_jqPdg{Sm2HdYzdEx zOGVPhVRTGPtv0o}RfVP;Nd(|CB)I;*t&QO8h zFfekr30S!-LHmV_Su-W+rEwYXJ^;6&3|L$mMC8*bQptyOo9;>Qb9Q9`ySe3%V$A*9 zeKEe+b0{#KWGp$F+tga)0RtI)nhMa-K@JS}2krK~n8vJ=Ngm?R!9G<~RyuU0d?nz# z-5EK$o(!F?hmX*2Yt6+coY`6jGbb7tF#6nHA zuKk=GGJ;ZwON1iAfG$E#Y7MnZVmrY|j0eVI(DN_MNFJmyZ|;w4tf@=CCDZ#5N_0K= z$;R~bbk?}TpfDjfB&aiQ$VA}s?P}xPERJG{kxk5~R`iRS(SK5d+Xs9swCozZISbnS zk!)I0>t=A<-^z(cmSFz3=jZ23u13X><0b)P)^1T_))Kr`e!-pb#q&J*Q`p+B6la%C zuVl&0duN<;uOsB3%T9Fp8t{ED108<+W(nOZd?gDnfNBC3>M8WE61$So|P zVvqH0SNtDTcsUdzaMDpT=Ty0pDHHNL@Z0w$Y`XO z2M-_r1S+GaH%pz#Uy0*w$Vdl=X=rQXEzO}d6J^R6zjM1u&c9vYLvLp?W7w(?np9x1 zE_0JSAJCPB%i7p*Wvg)pn5T`8k3-uR?*NT|J`eS#_#54p>!p(mLDvmc-3o0mX*mp_ zN*AeS<>#^-{S%W<*mz^!X$w_2dHWpcJ6^j64qFBft-o}o_Vx80o0>}Du;>kLts;$8 zC`7q$QI(dKYG`Wa8#wl@V4jVWBRGQ@1dr-hstpQL)Tl+aqVpGpbSfN>5i&QMXfiZ> zaA?T1VGe?rpQ@;+pkrVdd{klI&jVS@I5_iz!=UMpTsa~mBga?1r}aRBm1WS;TT*s0f0lY=JBl66Upy)-k4J}lh=P^8(SXk~0xW=T9v*B|gzIhN z>qsO7dFd~mgxAy4V?&)=5ieYq?zi?ZEoj)&2o)RLy=@hbCRcfT5jigwtQGE{L*8<@Yd{zg;CsL5mvzfDY}P-wos_6PfprFVaeqNE%h zKZhLtcQld;ZD+>=nqN~>GvROfueSzJD&BE*}XfU|H&(FssBqY=hPCt`d zH?@s2>I(|;fcW&YM6#V#!kUIP8$Nkdh0A(bEVj``-AAyYgwY~jB zT|I7Bf@%;7aL7Wf4dZ%VqF$eiaC38OV6oy3Z#TER2G+fOCd9Iaoy6aLYbPTN{XRPz z;U!V|vBf%H!}52L2gH_+j;`bTcQRXB+y9onc^wLm5wi3-Be}U>k_u>2Eg$=k!(l@I zcCg+flakT2Nej3i0yn+g+}%NYb?ta;R?(g5SnwsQ49U8Wng8d|{B+lyRcEDvR3+`O{zfmrmvFrL6acVP%yG98X zo&+VBg@px@i)%o?dG(`T;n*$S5*rnyiR#=wW}}GsAcfyQpE|>a{=$Hjg=-*_K;UtD z#z-)AXwSRY?OPefw^iI+ z)AXz#PfEjlwTes|_{sB?4(O@fg0AJ^g8gP}ex9Ucf*@_^J(s_5jJV}c)s$`Myn|Kd z$6>}#q^n{4vN@+Os$m7KV+`}c%4)4pv@06af4-x5#wj!KKb%caK{A&Y#Rfs z-po?Dcb1({W=6FKIUirH&(yg=*6aLCekcKwyfK^JN5{wcA3nhO(o}SK#!CINhI`-I z1)6&n7O&ZmyFMuNwvEic#IiOAwNkR=u5it{B9n2sAJV5pNhar=j5`*N!Na;c7g!l$ z3aYBqUkqqTJ=Re-;)s!EOeij=7SQZ3Hq}ZRds%IM*PtM$wV z@;rlc*NRK7i3y5BETSKuumEN`Xu_8GP1Ri=OKQ$@I^ko8>H6)4rjiG5{VBM>B|%`&&s^)jS|-_95&yc=GqjNo{zFkw%%HHhS~e=s zD#sfS+-?*t|J!+ozP6KvtOl!R)@@-z24}`9{QaVLD^9VCSR2b`b!KC#o;Ki<+wXB6 zx3&O0LOWcg4&rv4QG0)4yb}7BFSEg~=IR5#ZRj8kg}dS7_V&^%#Do==#`u zpy6{ox?jWuR(;pg+f@mT>#HGWHAJRRDDDv~@(IDw&R>9643kK#HN`!1vBJHnC+RM&yIh8{gG2q zA%e*U3|N0XSRa~oX-3EAneep)@{h2vvd3Xvy$7og(sayr@95+e6~Xvi1tUqnIxoIH zVWo*OwYElb#uyW{Imam6f2rGbjR!Y3`#gPqkv57dB6K^wRGxc9B(t|aYDGS=m$&S!NmCtrMMaUg(c zc2qC=2Z`EEFMW-me5B)24AqF*bV5Dr-M5ig(l-WPS%CgaPzs6p_gnCIvTJ=Y<6!gT zVt@AfYCzjjsMEGi=rDQHo0yc;HqoRNnNFeWZgcm?f;cp(6CNylj36DoL(?TS7eU#+ z7&mfr#y))+CJOXQKUMZ7QIdS9@#-}7y2K1{8)cCt0~-X0O!O?Qx#E4Og+;A2SjalQ zs7r?qn0H044=sDN$SRG$arw~n=+T_DNdSrarmu)V6@|?1-ZB#hRn`uilTGPJ@fqEy zGt(f0B+^JDP&f=r{#Y_wi#AVDf-y!RIXU^0jXsFpf>=Ji*TeqSY!H~AMbJdCGLhC) zn7Rx+sXw6uYj;WRYrLd^5IZq@6JI1C^YkgnedZEYy<&4(z%Q$5yv#Boo{AH8n$a zhb4Y3PWdr269&?V%uI$xMcUrMzl=;w<_nm*qr=c3Rl@i5wWB;e-`t7D&c-mcQl7x! zZWB`UGcw=Y2=}~wzrfLx=uet<;m3~=8I~ZRuzvMQUQdr+yTV|ATf1Uuomr__nDf=X zZ3WYJtHp_ri(}SQAPjv+Y+0=fH4krOP@S&=zZ-t1jW1o@}z;xk8 z(Nz1co&El^HK^NrhVHa-_;&88vTU>_J33=%{if;BEY*J#1n59=07jrGQ#IP>@u#3A z;!q+E1Rj3ZJ+!4bq9F8PXJ@yMgZL;>&gYA0%_Kbi8?S=XGM~dnQZQ!yBSgcZhY96H zrWnU;k)qy`rX&&xlDyA%(a1Hhi5CWkmg(`Gb%m(HKi-7Z!LKGRP_B8@`7&hdDy5n= z`OIxqxiVfX@OX1p(mQu>0Ai*v_cTMiw4qRt3~NBvr9oBy0)r>w3p~V0SCm=An6@3n)>@z!|o-$HvDK z|3D2ZMJkLE5loMKl6R^ez@Zz%S$&mbeoqH5`Bb){Ei21q&VP)hWS2tjShfFtGE+$z zzCR$P#uktu+#!w)cX!lWN1XU%K-r=s{|j?)Akf@q#3b#{6cZCuJ~gCxuMXRmI$nGtnH+-h z+GEi!*X=AP<|fG`1>MBdTb?28JYc=fGvAi2I<$B(rs$;eoJCyR6_bc~p!XR@O-+sD z=eH`-ye})I5ic1eL~TDmtfJ|8`0VJ*Yr=hNCd)G1p2MMz4C3^Mj?7;!w|Ly%JqmuW zlIEW^Ft%z?*|fpXda>Jr^1noFZEwFgVV%|*XhH@acv8rdGxeEX{M$(vG{Zw+x(ei@ zmfXb22}8-?Fi`vo-YVrTH*C?a8%M=Hv9MqVH7H^J$KsD?>!SFZ;ZsvnHr_gn=7acz z#W?0eCdVhVMWN12VV^$>WlQ?f;P^{(&pYTops|btm6aj>_Uz+hqpGwB)vWp0Cf5y< zft8-je~nn?W11plq}N)4A{l8I7$!ks_x$PXW-2XaRFswX_BnF{R#6YIwMhAgd5F9X zGmwdadS6(a^fjHtXg8=l?Rc0Sm%hk6E9!5cLVloEy4eh(=FwgP`)~I^5~pBEWo+F6 zSf2ncyMurJN91#cJTy_u8Y}@%!bq1RkGC~-bV@SXRd4F{R-*V`bS+6;W5vZ(&+I<9$;-V|eNfLa5n-6% z2(}&uGRF;p92eS*sE*oR$@pexaqr*meB)VhmIg@h{uzkk$9~qh#cHhw#>O%)b@+(| z^IQgqzuj~Sk(J;swEM-3TrJAPCq9k^^^`q{IItKBRXYe}e0Tdr=Huf7da3$l4PdpwWDop%^}n;dD#K4s#DYA8SHZ z&1!riV4W4R7R#C))JH1~axJ)RYnM$$lIR%6fIVA@zV{XVyx}C+a-Dt8Y9M)^KU0+H zR4IUb2CJ{Hg>CuaXtD50jB(_Tcx=Z$^WYu2u5kubqmwp%drJ6 z?Fo40g!Qd<-l=TQxqHEOuPX0;^z7iX?Ke^a%XT<13TA^5`4Xcw6D@Ur&VT&CUe0d} z1GjOVF1^L@>O)l@?bD~$wzgf(nxX1OGD8fEV?TdJcZc2KoUe|oP1#=$$7ee|xbY)A zDZq+cuTpc(fFdj^=!;{k03C69lMQ(|>uhRfRu%+!k&YOi-3|1QKB z z?n?eq1XP>p-IM$Z^C;2L3itnbJZAip*Zo0aw2bs8@(s^~*8T9go!%dHcAz2lM;`yp zD=7&xjFV$S&5uDaiScyD?B-i1ze`+CoRtz`Wn+Zl&#s4&}MO{@N!ufrzjG$B79)Y2d3tBk&)TxUTw@QS0TEL_?njX|@vq?Uz(nBFK5Pq7*xj#u*R&i|?7+6# z+|r_n#SW&LXhtheZdah{ZVoqwyT{D>MC3nkFF#N)xLi{p7J1jXlmVeb;cP5?e(=f# zuT7fvjSbjS781v?7{)-X3*?>tq?)Yd)~|1{BDS(pqC zC}~H#WXlkUW*H5CDOo<)#x7%RY)A;ShGhI5s*#cRDA8YgqG(HeKDx+#(ZQ?386dv! zlXCO)w91~Vw4AmOcATuV653fa9R$fyK8ul%rG z-wfS zihugoZyr38Im?Zuh6@RcF~t1anQu7>#lPpb#}4cOA!EM11`%f*07RqOVkmX{p~KJ9 z^zP;K#|)$`^Rb{rnHGH{~>1(fawV0*Z#)}M`m8-?ZJV<+e}s9wE# z)l&az?w^5{)`S(%MRzxdNqrs1n*-=jS^_jqE*5XDrA0+VE`5^*p3CuM<&dZEeCjoz zR;uu_H9ZPZV|fQq`Cyw4nscrVwi!fE6ciMmX$!_hN7uF;jjKG)d2@aC4ropY)8etW=xJvni)8eHi`H$%#zn^WJ5NLc-rqk|u&&4Z6fD_m&JfSI1Bvb?b<*n&sfl0^t z=HnmRl`XrFvMKB%9}>PaA`m-fK6a0(8=qPkWS5bb4=v?XcWi&hRY?O5HdulRi4?fN zlsJ*N-0Qw+Yic@s0(2uy%F@ib;GjXt01Fmx5XbRo6+n|pP(&nodMoap^z{~q ziEeaUT@Mxe3vJSfI6?uLND(CNr=#^W<1b}jzW58bIfyWTDle$mmS(|x-0|2UlX+9k zQ^EX7Nw}?EzVoBfT(-LT|=9N@^hcn-_p&sqG z&*oVs2JSU+N4ZD`FhCAWaS;>|wH2G*Id|?pa#@>tyxX`+4HyIArWDvVrX)2WAOQff z0qyHu&-S@i^MS-+j--!pr4fPBj~_8({~e1bfcl0wI1kaoN>mJL6KUPQm5N7lB(ui1 zE-o%kq)&djzWJ}ob<-GfDlkB;F31j-VHKvQUGQ3sp`CwyGJk_i!y^sD0fqC@$9|jO zOqN!r!8-p==F@ZVP=U$qSpY(gQ0)59P1&t@y?5rvg<}E+GB}26NYPp4f2YFQrQtot5mn3wu_qprZ=>Ig-$ zbW26Ws~IgY>}^5w`vTB(G`PTZaDiGBo5o(tp)qli|NeV( z@H_=R8V39rt5J5YB2Ky?4eJJ#b`_iBe2ot~6%7mLt5t8Vwi^Jy7|jWXqa3amOIoRb zOr}WVFP--DsS`1WpN%~)t3R!arKF^Q$e12KEqU36AWwnCBICpH4XCsfnyrHr>$I$4 z!DpKX$OKLWarN7nv@!uIA+~RNO)l$$w}p(;b>mx8pwYvu;dD_unryX_NhT8*Tj>BTrTTL&!?O+%Rv;b?B??gSzdp?6Uug9{ zd@V08Z$BdI?fpoCS$)t4mg4rT8Q_I}h`0d-vYZ^|dOB*Q^S|xqTV*vIg?@fVFSmMpaw0qtTRbx} z({Pg?#{2`sc9)M5N$*N|4;^t$+QP?#mov zGVC@I*lBVrOU-%2y!7%)fAKjpEFsgQc4{amtiHb95KQEwvf<(3T<9-Zm$xIew#P22 zc2Ix|App^>v6(3L_MCU0d3W##AB0M~3D00EWoKZqsJYT(#@w$Y_H7G22M~ApVFTRHMI_3be)Lkn#0F*V8Pq zc}`Cjy$bE;FJ6H7p=0y#R>`}-m4(0F>%@P|?7fx{=R^uFdISRnZ2W_xQhD{YuR3t< z{6yxu=4~JkeA;|(J6_nv#>Nvs&FuLA&PW^he@t(UwFFE8)|a!R{`E`K`i^ZnyE4$k z;(749Ix|oi$c3QbEJ3b~D_kQsPz~fIUKym($a_7dJ?o+40*OLl^{=&oq$<#Q(yyrp z{J-FAniyAw9tPbe&IhQ|a`DqFTVQGQ&Gq3!C2==4x{6EJwiPZ8zub-iXoUtkJiG{} zPaR&}_fn8_z~(=;5lD-aPWD3z8PZS@AaUiomF!G8I}Mf>e~0g#BelA-5#`cj;O5>N Xviia!U7SGha1wx#SCgwmn*{w2TRX*I literal 0 HcmV?d00001 diff --git a/account_bank_statement_import_online_ponto/tests/__init__.py b/account_bank_statement_import_online_ponto/tests/__init__.py new file mode 100644 index 00000000..8e1252ec --- /dev/null +++ b/account_bank_statement_import_online_ponto/tests/__init__.py @@ -0,0 +1,3 @@ +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from . import test_account_bank_statement_import_online_ponto diff --git a/account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py b/account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py new file mode 100644 index 00000000..8b4353b0 --- /dev/null +++ b/account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py @@ -0,0 +1,128 @@ +# Copyright 2020 Florent de Labarre +# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). + +from datetime import datetime +from unittest import mock + +from odoo import fields +from odoo.tests import common + +_module_ns = 'odoo.addons.account_bank_statement_import_online_ponto' +_provider_class = ( + _module_ns + + '.models.online_bank_statement_provider_ponto' + + '.OnlineBankStatementProviderPonto' +) + + +class TestAccountBankAccountStatementImportOnlineQonto( + common.TransactionCase +): + + def setUp(self): + super().setUp() + + self.now = fields.Datetime.now() + self.currency_eur = self.env.ref('base.EUR') + self.currency_usd = self.env.ref('base.USD') + self.AccountJournal = self.env['account.journal'] + self.ResPartnerBank = self.env['res.partner.bank'] + self.OnlineBankStatementProvider = self.env[ + 'online.bank.statement.provider' + ] + self.AccountBankStatement = self.env['account.bank.statement'] + self.AccountBankStatementLine = self.env['account.bank.statement.line'] + + self.bank_account = self.ResPartnerBank.create( + {'acc_number': 'FR0214508000302245362775K46', + 'partner_id': self.env.user.company_id.partner_id.id}) + self.journal = self.AccountJournal.create({ + 'name': 'Bank', + 'type': 'bank', + 'code': 'BANK', + 'currency_id': self.currency_eur.id, + 'bank_statements_source': 'online', + 'online_bank_statement_provider': 'ponto', + 'bank_account_id': self.bank_account.id, + }) + self.provider = self.journal.online_bank_statement_provider_id + + self.mock_header = lambda: mock.patch( + _provider_class + '._ponto_header', + return_value={'Accept': 'application/json', + 'Authorization': 'Bearer --TOKEN--'}, + ) + + self.mock_account_ids = lambda: mock.patch( + _provider_class + '._ponto_get_account_ids', + return_value={'FR0214508000302245362775K46': 'id'}, + ) + self.mock_synchronisation = lambda: mock.patch( + _provider_class + '._ponto_synchronisation', + return_value=None, + ) + + self.mock_transaction = lambda: mock.patch( + _provider_class + '._ponto_get_transaction', + return_value=[{ + 'type': 'transaction', + 'relationships': {'account': { + 'links': { + 'related': 'https://api.myponto.com/accounts/'}, + 'data': {'type': 'account', + 'id': 'fd3d5b1d-fca9-4310-a5c8-76f2a9dc7c75'}}}, + 'id': '701ab965-21c4-46ca-b157-306c0646e0e2', + 'attributes': {'valueDate': '2019-11-18T00:00:00.000Z', + 'remittanceInformationType': 'unstructured', + 'remittanceInformation': 'Minima vitae totam!', + 'executionDate': '2019-11-20T00:00:00.000Z', + 'description': 'Wire transfer', + 'currency': 'EUR', + 'counterpartReference': 'BE26089479973169', + 'counterpartName': 'Osinski Group', + 'amount': 6.08}}, + {'type': 'transaction', + 'relationships': { + 'account': {'links': { + 'related': 'https://api.myponto.com/accounts/'}, + 'data': { + 'type': 'account', + 'id': 'fd3d5b1d-fca9-4310-a5c8-76f2a9dc7c75'}}}, + 'id': '9ac50483-16dc-4a82-aa60-df56077405cd', + 'attributes': { + 'valueDate': '2019-11-04T00:00:00.000Z', + 'remittanceInformationType': 'unstructured', + 'remittanceInformation': 'Quia voluptatem blanditiis.', + 'executionDate': '2019-11-06T00:00:00.000Z', + 'description': 'Wire transfer', + 'currency': 'EUR', + 'counterpartReference': 'BE97201830401438', + 'counterpartName': 'Stokes-Miller', + 'amount': 5.48}}, + {'type': 'transaction', 'relationships': {'account': {'links': { + 'related': 'https://api.myponto.com/accounts/'}, + 'data': { + 'type': 'account', + 'id': 'fd3d5b1d-fca9-4310-a5c8-76f2a9dc7c75'}}}, + 'id': 'b21a6c65-1c52-4ba6-8cbc-127d2b2d85ff', + 'attributes': { + 'valueDate': '2019-11-04T00:00:00.000Z', + 'remittanceInformationType': 'unstructured', + 'remittanceInformation': 'Laboriosam repelo?', + 'executionDate': '2019-11-04T00:00:00.000Z', + 'description': 'Wire transfer', 'currency': 'EUR', + 'counterpartReference': 'BE10325927501996', + 'counterpartName': 'Strosin-Veum', 'amount': 5.83}}], + ) + + def test_ponto(self): + with self.mock_transaction(), \ + self.mock_header(),\ + self.mock_synchronisation(), \ + self.mock_account_ids(): + lines, statement_values = self.provider._obtain_statement_data( + datetime(2019, 11, 3), + datetime(2019, 11, 17), + ) + + self.assertEqual(len(lines), 3) diff --git a/account_bank_statement_import_online_ponto/view/online_bank_statement_provider.xml b/account_bank_statement_import_online_ponto/view/online_bank_statement_provider.xml new file mode 100644 index 00000000..e856cf56 --- /dev/null +++ b/account_bank_statement_import_online_ponto/view/online_bank_statement_provider.xml @@ -0,0 +1,19 @@ + + + + online.bank.statement.provider.form + online.bank.statement.provider + + + + + + + +
diff --git a/account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py b/account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py index d1b912c8..73d62fea 100644 --- a/account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py +++ b/account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py @@ -142,7 +142,7 @@ class TestAccountBankAccountStatementImportOnlineQonto(common.TransactionCase): ) def test_ponto(self): - with self.mock_transaction(), self.mock_header(), self.mock_synchronisation(), self.mock_account_ids(): + with self.mock_transaction(), self.mock_header(), self.mock_synchronisation(), self.mock_account_ids(): # noqa: B950 lines, statement_values = self.provider._obtain_statement_data( datetime(2019, 11, 3), datetime(2019, 11, 17), ) diff --git a/account_bank_statement_import_online_ponto/view/online_bank_statement_provider.xml b/account_bank_statement_import_online_ponto/view/online_bank_statement_provider.xml index 990af143..d487be5c 100644 --- a/account_bank_statement_import_online_ponto/view/online_bank_statement_provider.xml +++ b/account_bank_statement_import_online_ponto/view/online_bank_statement_provider.xml @@ -9,7 +9,7 @@ /> - + From 93631279d9be443d11ced00a9d581da6bd47060c Mon Sep 17 00:00:00 2001 From: oca-travis Date: Tue, 22 Dec 2020 18:46:44 +0000 Subject: [PATCH 28/32] [UPD] Update account_bank_statement_import_online_ponto.pot --- ...unt_bank_statement_import_online_ponto.pot | 30 ++++++++++--------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/account_bank_statement_import_online_ponto/i18n/account_bank_statement_import_online_ponto.pot b/account_bank_statement_import_online_ponto/i18n/account_bank_statement_import_online_ponto.pot index bb0bf26f..2dc153e6 100644 --- a/account_bank_statement_import_online_ponto/i18n/account_bank_statement_import_online_ponto.pot +++ b/account_bank_statement_import_online_ponto/i18n/account_bank_statement_import_online_ponto.pot @@ -1,12 +1,12 @@ # Translation of Odoo Server. # This file contains the translation of the following modules: -# * account_bank_statement_import_online_ponto +# * account_bank_statement_import_online_ponto # msgid "" msgstr "" -"Project-Id-Version: Odoo Server 12.0\n" +"Project-Id-Version: Odoo Server 13.0\n" "Report-Msgid-Bugs-To: \n" -"Last-Translator: <>\n" +"Last-Translator: \n" "Language-Team: \n" "MIME-Version: 1.0\n" "Content-Type: text/plain; charset=UTF-8\n" @@ -14,26 +14,29 @@ msgstr "" "Plural-Forms: \n" #. module: account_bank_statement_import_online_ponto -#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:80 -#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:96 +#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 +#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 #, python-format -msgid "%s \n" +msgid "" +"%s \n" "\n" " %s" msgstr "" #. module: account_bank_statement_import_online_ponto -#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:115 +#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 #, python-format -msgid "Error during Create Synchronisation %s \n" +msgid "" +"Error during Create Synchronisation %s \n" "\n" " %s" msgstr "" #. module: account_bank_statement_import_online_ponto -#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:170 +#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 #, python-format -msgid "Error during get transaction.\n" +msgid "" +"Error during get transaction.\n" "\n" "%s \n" "\n" @@ -51,19 +54,19 @@ msgid "Online Bank Statement Provider" msgstr "" #. module: account_bank_statement_import_online_ponto -#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:57 +#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 #, python-format msgid "Please fill login and key." msgstr "" #. module: account_bank_statement_import_online_ponto -#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:73 +#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 #, python-format msgid "Ponto : no token" msgstr "" #. module: account_bank_statement_import_online_ponto -#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:194 +#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 #, python-format msgid "Ponto : wrong configuration, unknow account %s" msgstr "" @@ -92,4 +95,3 @@ msgstr "" #: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online_ponto.online_bank_statement_provider_form msgid "Secret Key" msgstr "" - From cf39daaea079dba0d9a734955d69e32b6a109daa Mon Sep 17 00:00:00 2001 From: Ronald Portier Date: Fri, 28 May 2021 14:29:19 +0200 Subject: [PATCH 29/32] [IMP] account_bank_statement_import_online_ponto: black, isort, prettier --- .../test_account_bank_statement_import_online_ponto.py | 6 ++++-- .../odoo/addons/account_bank_statement_import_online_ponto | 1 + setup/account_bank_statement_import_online_ponto/setup.py | 6 ++++++ 3 files changed, 11 insertions(+), 2 deletions(-) create mode 120000 setup/account_bank_statement_import_online_ponto/odoo/addons/account_bank_statement_import_online_ponto create mode 100644 setup/account_bank_statement_import_online_ponto/setup.py diff --git a/account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py b/account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py index 73d62fea..8f355c00 100644 --- a/account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py +++ b/account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py @@ -60,7 +60,8 @@ class TestAccountBankAccountStatementImportOnlineQonto(common.TransactionCase): return_value={"FR0214508000302245362775K46": "id"}, ) self.mock_synchronisation = lambda: mock.patch( - _provider_class + "._ponto_synchronisation", return_value=None, + _provider_class + "._ponto_synchronisation", + return_value=None, ) self.mock_transaction = lambda: mock.patch( @@ -144,7 +145,8 @@ class TestAccountBankAccountStatementImportOnlineQonto(common.TransactionCase): def test_ponto(self): with self.mock_transaction(), self.mock_header(), self.mock_synchronisation(), self.mock_account_ids(): # noqa: B950 lines, statement_values = self.provider._obtain_statement_data( - datetime(2019, 11, 3), datetime(2019, 11, 17), + datetime(2019, 11, 3), + datetime(2019, 11, 17), ) self.assertEqual(len(lines), 3) diff --git a/setup/account_bank_statement_import_online_ponto/odoo/addons/account_bank_statement_import_online_ponto b/setup/account_bank_statement_import_online_ponto/odoo/addons/account_bank_statement_import_online_ponto new file mode 120000 index 00000000..e413ef48 --- /dev/null +++ b/setup/account_bank_statement_import_online_ponto/odoo/addons/account_bank_statement_import_online_ponto @@ -0,0 +1 @@ +../../../../account_bank_statement_import_online_ponto \ No newline at end of file diff --git a/setup/account_bank_statement_import_online_ponto/setup.py b/setup/account_bank_statement_import_online_ponto/setup.py new file mode 100644 index 00000000..28c57bb6 --- /dev/null +++ b/setup/account_bank_statement_import_online_ponto/setup.py @@ -0,0 +1,6 @@ +import setuptools + +setuptools.setup( + setup_requires=['setuptools-odoo'], + odoo_addon=True, +) From 5d62d497d92298ecf9687892d2f0e5e7543ab5a2 Mon Sep 17 00:00:00 2001 From: Ronald Portier Date: Fri, 28 May 2021 14:57:23 +0200 Subject: [PATCH 30/32] [IMP] Adapt account_bank_statement_import_online to 14.0 Also Rename account_bank_statement_import_online => account_statement_import_online --- .../account_bank_statement_import_online.pot | 485 ----------------- .../i18n/nl.po | 491 ------------------ .../13.0.1.0.0/noupdate_changes.xml | 13 - .../migrations/13.0.1.0.0/post-migration.py | 14 - .../views/account_journal.xml | 132 ----- ...unt_bank_statement_import_online_ponto.pot | 97 ---- .../README.rst | 14 +- .../__init__.py | 0 .../__manifest__.py | 6 +- .../data/account_statement_import_online.xml | 2 +- .../i18n/account_statement_import_online.pot | 485 +++++++++++++++++ account_statement_import_online/i18n/nl.po | 491 ++++++++++++++++++ .../models/__init__.py | 0 .../models/account_journal.py | 0 .../models/online_bank_statement_provider.py | 218 ++++---- .../readme/CONFIGURE.rst | 0 .../readme/CONTRIBUTORS.rst | 4 + .../readme/DESCRIPTION.rst | 0 .../readme/USAGE.rst | 0 .../security/ir.model.access.csv | 1 + .../online_bank_statement_provider.xml | 0 .../static/description/icon.png | Bin .../static/description/index.html | 10 +- .../tests/__init__.py | 0 .../online_bank_statement_provider_dummy.py | 0 ...st_account_bank_statement_import_online.py | 0 .../views/account_journal.xml | 63 +++ .../views/online_bank_statement_provider.xml | 0 .../wizards/__init__.py | 0 .../online_bank_statement_pull_wizard.py | 0 .../online_bank_statement_pull_wizard.xml | 0 .../README.rst | 14 +- .../__init__.py | 1 - .../__manifest__.py | 4 +- .../account_statement_import_online_ponto.pot | 97 ++++ .../models/__init__.py | 1 - .../online_bank_statement_provider_ponto.py | 0 .../readme/CONFIGURE.rst | 0 .../readme/CONTRIBUTORS.rst | 4 + .../readme/DESCRIPTION.rst | 0 .../readme/USAGE.rst | 0 .../static/description/icon.png | Bin .../static/description/index.html | 10 +- .../tests/__init__.py | 2 +- ...t_account_statement_import_online_ponto.py | 2 +- .../view/online_bank_statement_provider.xml | 2 +- .../account_bank_statement_import_online | 1 - ...account_bank_statement_import_online_ponto | 1 - .../addons/account_statement_import_online | 1 + .../setup.py | 0 .../account_statement_import_online_ponto | 1 + .../setup.py | 0 52 files changed, 1300 insertions(+), 1367 deletions(-) delete mode 100644 account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot delete mode 100644 account_bank_statement_import_online/i18n/nl.po delete mode 100644 account_bank_statement_import_online/migrations/13.0.1.0.0/noupdate_changes.xml delete mode 100644 account_bank_statement_import_online/migrations/13.0.1.0.0/post-migration.py delete mode 100644 account_bank_statement_import_online/views/account_journal.xml delete mode 100644 account_bank_statement_import_online_ponto/i18n/account_bank_statement_import_online_ponto.pot rename {account_bank_statement_import_online => account_statement_import_online}/README.rst (87%) rename {account_bank_statement_import_online => account_statement_import_online}/__init__.py (100%) rename {account_bank_statement_import_online => account_statement_import_online}/__manifest__.py (87%) rename account_bank_statement_import_online/data/account_bank_statement_import_online.xml => account_statement_import_online/data/account_statement_import_online.xml (89%) create mode 100644 account_statement_import_online/i18n/account_statement_import_online.pot create mode 100644 account_statement_import_online/i18n/nl.po rename {account_bank_statement_import_online => account_statement_import_online}/models/__init__.py (100%) rename {account_bank_statement_import_online => account_statement_import_online}/models/account_journal.py (100%) rename {account_bank_statement_import_online => account_statement_import_online}/models/online_bank_statement_provider.py (70%) rename {account_bank_statement_import_online => account_statement_import_online}/readme/CONFIGURE.rst (100%) rename {account_bank_statement_import_online => account_statement_import_online}/readme/CONTRIBUTORS.rst (55%) rename {account_bank_statement_import_online => account_statement_import_online}/readme/DESCRIPTION.rst (100%) rename {account_bank_statement_import_online => account_statement_import_online}/readme/USAGE.rst (100%) rename {account_bank_statement_import_online => account_statement_import_online}/security/ir.model.access.csv (69%) rename {account_bank_statement_import_online => account_statement_import_online}/security/online_bank_statement_provider.xml (100%) rename {account_bank_statement_import_online => account_statement_import_online}/static/description/icon.png (100%) rename {account_bank_statement_import_online => account_statement_import_online}/static/description/index.html (91%) rename {account_bank_statement_import_online => account_statement_import_online}/tests/__init__.py (100%) rename {account_bank_statement_import_online => account_statement_import_online}/tests/online_bank_statement_provider_dummy.py (100%) rename {account_bank_statement_import_online => account_statement_import_online}/tests/test_account_bank_statement_import_online.py (100%) create mode 100644 account_statement_import_online/views/account_journal.xml rename {account_bank_statement_import_online => account_statement_import_online}/views/online_bank_statement_provider.xml (100%) rename {account_bank_statement_import_online => account_statement_import_online}/wizards/__init__.py (100%) rename {account_bank_statement_import_online => account_statement_import_online}/wizards/online_bank_statement_pull_wizard.py (100%) rename {account_bank_statement_import_online => account_statement_import_online}/wizards/online_bank_statement_pull_wizard.xml (100%) rename {account_bank_statement_import_online_ponto => account_statement_import_online_ponto}/README.rst (87%) rename {account_bank_statement_import_online_ponto => account_statement_import_online_ponto}/__init__.py (70%) rename {account_bank_statement_import_online_ponto => account_statement_import_online_ponto}/__manifest__.py (84%) create mode 100644 account_statement_import_online_ponto/i18n/account_statement_import_online_ponto.pot rename {account_bank_statement_import_online_ponto => account_statement_import_online_ponto}/models/__init__.py (76%) rename {account_bank_statement_import_online_ponto => account_statement_import_online_ponto}/models/online_bank_statement_provider_ponto.py (100%) rename {account_bank_statement_import_online_ponto => account_statement_import_online_ponto}/readme/CONFIGURE.rst (100%) rename {account_bank_statement_import_online_ponto => account_statement_import_online_ponto}/readme/CONTRIBUTORS.rst (58%) rename {account_bank_statement_import_online_ponto => account_statement_import_online_ponto}/readme/DESCRIPTION.rst (100%) rename {account_bank_statement_import_online_ponto => account_statement_import_online_ponto}/readme/USAGE.rst (100%) rename {account_bank_statement_import_online_ponto => account_statement_import_online_ponto}/static/description/icon.png (100%) rename {account_bank_statement_import_online_ponto => account_statement_import_online_ponto}/static/description/index.html (90%) rename {account_bank_statement_import_online_ponto => account_statement_import_online_ponto}/tests/__init__.py (51%) rename account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py => account_statement_import_online_ponto/tests/test_account_statement_import_online_ponto.py (98%) rename {account_bank_statement_import_online_ponto => account_statement_import_online_ponto}/view/online_bank_statement_provider.xml (92%) delete mode 120000 setup/account_bank_statement_import_online/odoo/addons/account_bank_statement_import_online delete mode 120000 setup/account_bank_statement_import_online_ponto/odoo/addons/account_bank_statement_import_online_ponto create mode 120000 setup/account_statement_import_online/odoo/addons/account_statement_import_online rename setup/{account_bank_statement_import_online => account_statement_import_online}/setup.py (100%) create mode 120000 setup/account_statement_import_online_ponto/odoo/addons/account_statement_import_online_ponto rename setup/{account_bank_statement_import_online_ponto => account_statement_import_online_ponto}/setup.py (100%) diff --git a/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot b/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot deleted file mode 100644 index 54e7742a..00000000 --- a/account_bank_statement_import_online/i18n/account_bank_statement_import_online.pot +++ /dev/null @@ -1,485 +0,0 @@ -# Translation of Odoo Server. -# This file contains the translation of the following modules: -# * account_bank_statement_import_online -# -msgid "" -msgstr "" -"Project-Id-Version: Odoo Server 13.0\n" -"Report-Msgid-Bugs-To: \n" -"Last-Translator: \n" -"Language-Team: \n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: \n" -"Plural-Forms: \n" - -#. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 -#, python-format -msgid "%(number)s %(type)s" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction -msgid "Action Needed" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__active -msgid "Active" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__api_base -msgid "Api Base" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_attachment_count -msgid "Attachment Count" -msgstr "" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form -msgid "Cancel" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate -msgid "Certificate" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_chain -msgid "Certificate Chain" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_private_key -msgid "Certificate Private Key" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_public_key -msgid "Certificate Public Key" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__company_id -msgid "Company" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__company_id -msgid "Company related to this journal" -msgstr "" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form -msgid "Configuration" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__create_uid -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__create_uid -msgid "Created by" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__create_date -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__create_date -msgid "Created on" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__currency_id -msgid "Currency" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__daily -msgid "Daily statements" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__days -msgid "Day(s)" -msgstr "" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form -msgid "Details" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__display_name -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__display_name -msgid "Display Name" -msgstr "" - -#. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 -#, python-format -msgid "" -"Failed to obtain statement data for period since %s until %s: %s. See server" -" logs for more details." -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_follower_ids -msgid "Followers" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_channel_ids -msgid "Followers (Channels)" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_partner_ids -msgid "Followers (Partners)" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__hours -msgid "Hour(s)" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__id -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__id -msgid "ID" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread -msgid "If checked, new messages require your attention." -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_sms_error -msgid "If checked, some messages have a delivery error." -msgstr "" - -#. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_filter -#, python-format -msgid "Inactive" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__interval_type -msgid "Interval Type" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_is_follower -msgid "Is Follower" -msgstr "" - -#. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 -#, python-format -msgid "Issue with Online Bank Statement Provider" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model,name:account_bank_statement_import_online.model_account_journal -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__journal_id -msgid "Journal" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__key -msgid "Key" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider____last_update -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard____last_update -msgid "Last Modified on" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__write_uid -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__write_uid -msgid "Last Updated by" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__write_date -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__write_date -msgid "Last Updated on" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__last_successful_run -msgid "Last successful pull" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_main_attachment_id -msgid "Main Attachment" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error -msgid "Message Delivery error" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_ids -msgid "Messages" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__minutes -msgid "Minute(s)" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__monthly -msgid "Monthly statements" -msgstr "" - -#. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 -#, python-format -msgid "N/A" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__name -msgid "Name" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__next_run -msgid "Next scheduled pull" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction_counter -msgid "Number of Actions" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error_counter -msgid "Number of errors" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction_counter -msgid "Number of messages which requires an action" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error_counter -msgid "Number of messages with delivery error" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread_counter -msgid "Number of unread messages" -msgstr "" - -#. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/account_journal.py:0 -#, python-format -msgid "Online (OCA)" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model,name:account_bank_statement_import_online.model_online_bank_statement_provider -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_bank_statement_import_journal_creation__online_bank_statement_provider -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_journal__online_bank_statement_provider -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form -msgid "Online Bank Statement Provider" -msgstr "" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_filter -msgid "Online Bank Statement Providers" -msgstr "" - -#. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/account_journal.py:0 -#: model:ir.model,name:account_bank_statement_import_online.model_online_bank_statement_pull_wizard -#, python-format -msgid "Online Bank Statement Pull Wizard" -msgstr "" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_bank_journal_form -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_journal_form -msgid "Online Bank Statements (OCA)" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.actions.server,name:account_bank_statement_import_online.action_online_bank_statements_pull_wizard -msgid "Online Bank Statements Pull Wizard" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.constraint,message:account_bank_statement_import_online.constraint_online_bank_statement_provider_journal_id_uniq -msgid "Only one online banking statement provider per journal!" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__origin -msgid "Origin" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__passphrase -msgid "Passphrase" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__password -msgid "Password" -msgstr "" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_bank_journal_form -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_journal_form -msgid "Provider" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__provider_ids -msgid "Providers" -msgstr "" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form -msgid "Pull" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.actions.server,name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements_ir_actions_server -#: model:ir.cron,cron_name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements -#: model:ir.cron,name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements -msgid "Pull Online Bank Statements" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_sms_error -msgid "SMS Delivery error" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__account_number -msgid "Sanitized Account Number" -msgstr "" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form -msgid "Scheduled Pull" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__interval_number -msgid "Scheduled update interval" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.constraint,message:account_bank_statement_import_online.constraint_online_bank_statement_provider_valid_interval_number -msgid "Scheduled update interval must be greater than zero!" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__service -msgid "Service" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__date_since -msgid "Since" -msgstr "" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form -msgid "Since (at least)" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__statement_creation_mode -msgid "Statement Creation Mode" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_bank_statement_import_journal_creation__online_bank_statement_provider_id -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_journal__online_bank_statement_provider_id -msgid "Statement Provider" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__currency_id -msgid "The currency used to enter statement" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__tz -msgid "Timezone" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__tz -msgid "" -"Timezone to convert transaction timestamps to prior being saved into a " -"statement." -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread -msgid "Unread Messages" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread_counter -msgid "Unread Messages Counter" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__date_until -msgid "Until" -msgstr "" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form -msgid "Until (at least)" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__update_schedule -msgid "Update Schedule" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__username -msgid "Username" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__website_message_ids -msgid "Website Messages" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__website_message_ids -msgid "Website communication history" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__weeks -msgid "Week(s)" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__weekly -msgid "Weekly statements" -msgstr "" diff --git a/account_bank_statement_import_online/i18n/nl.po b/account_bank_statement_import_online/i18n/nl.po deleted file mode 100644 index ed187a9f..00000000 --- a/account_bank_statement_import_online/i18n/nl.po +++ /dev/null @@ -1,491 +0,0 @@ -# Translation of Odoo Server. -# This file contains the translation of the following modules: -# * account_bank_statement_import_online -# -msgid "" -msgstr "" -"Project-Id-Version: Odoo Server 13.0\n" -"Report-Msgid-Bugs-To: \n" -"PO-Revision-Date: 2021-04-23 18:47+0000\n" -"Last-Translator: Bosd \n" -"Language-Team: none\n" -"Language: nl\n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: \n" -"Plural-Forms: nplurals=2; plural=n != 1;\n" -"X-Generator: Weblate 4.3.2\n" - -#. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 -#, python-format -msgid "%(number)s %(type)s" -msgstr "%(number)s %(type)s" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction -msgid "Action Needed" -msgstr "Actie vereist" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__active -msgid "Active" -msgstr "Actief" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__api_base -msgid "Api Base" -msgstr "Api Base" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_attachment_count -msgid "Attachment Count" -msgstr "Aantal Bijlagen" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form -msgid "Cancel" -msgstr "Annuleer" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate -msgid "Certificate" -msgstr "Certificaat" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_chain -msgid "Certificate Chain" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_private_key -msgid "Certificate Private Key" -msgstr "Certificaat privé sleutel" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__certificate_public_key -msgid "Certificate Public Key" -msgstr "Certificaat publieke sleutel" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__company_id -msgid "Company" -msgstr "Bedrijf" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__company_id -msgid "Company related to this journal" -msgstr "Bedrijf gerelateerd aan dit dagboek" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form -msgid "Configuration" -msgstr "Configuratie" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__create_uid -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__create_uid -msgid "Created by" -msgstr "Aangemaakt door" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__create_date -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__create_date -msgid "Created on" -msgstr "Aangemaakt op" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__currency_id -msgid "Currency" -msgstr "Valuta" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__daily -msgid "Daily statements" -msgstr "Dagelijks afschrift" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__days -msgid "Day(s)" -msgstr "Dag(en)" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form -msgid "Details" -msgstr "Details" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__display_name -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__display_name -msgid "Display Name" -msgstr "Weergavenaam" - -#. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 -#, python-format -msgid "" -"Failed to obtain statement data for period since %s until %s: %s. See server" -" logs for more details." -msgstr "" -"Kon de afschriften niet verkrijgen voor de periode van %s tot %s:%s. Bekijk " -"de error log van de server voor details." - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_follower_ids -msgid "Followers" -msgstr "Volgers" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_channel_ids -msgid "Followers (Channels)" -msgstr "Volgers (Kanalen)" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_partner_ids -msgid "Followers (Partners)" -msgstr "Volgers (Partners)" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__hours -msgid "Hour(s)" -msgstr "Uur/Uren" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__id -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__id -msgid "ID" -msgstr "ID" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread -msgid "If checked, new messages require your attention." -msgstr "Indien aangevinkt, nieuwe berichten vereisen uw aandacht." - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_sms_error -msgid "If checked, some messages have a delivery error." -msgstr "Indien aangevinkt, sommige berichten hebben een foutmelding." - -#. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_filter -#, python-format -msgid "Inactive" -msgstr "inactief" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__interval_type -msgid "Interval Type" -msgstr "Interval Type" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_is_follower -msgid "Is Follower" -msgstr "Is volger" - -#. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 -#, python-format -msgid "Issue with Online Bank Statement Provider" -msgstr "Probleem met Online Bank afschrift leverancier" - -#. module: account_bank_statement_import_online -#: model:ir.model,name:account_bank_statement_import_online.model_account_journal -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__journal_id -msgid "Journal" -msgstr "Dagboek" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__key -msgid "Key" -msgstr "Sleutel" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider____last_update -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard____last_update -msgid "Last Modified on" -msgstr "Laatst bijgewerkt op" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__write_uid -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__write_uid -msgid "Last Updated by" -msgstr "Laatst bijgewerkt door" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__write_date -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__write_date -msgid "Last Updated on" -msgstr "Laatst bijgewerkt op" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__last_successful_run -msgid "Last successful pull" -msgstr "Laatst succesvolle opvraag" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_main_attachment_id -msgid "Main Attachment" -msgstr "Hoofdbijlage" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error -msgid "Message Delivery error" -msgstr "Berichtafleverinsfout" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_ids -msgid "Messages" -msgstr "Berichten" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__minutes -msgid "Minute(s)" -msgstr "Minuut/Minuten" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__monthly -msgid "Monthly statements" -msgstr "Maandelijkse afschriften" - -#. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/online_bank_statement_provider.py:0 -#, python-format -msgid "N/A" -msgstr "N.V.T." - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__name -msgid "Name" -msgstr "Naam" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__next_run -msgid "Next scheduled pull" -msgstr "Volgende geplande opvraag" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction_counter -msgid "Number of Actions" -msgstr "Aantal acties" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error_counter -msgid "Number of errors" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_needaction_counter -msgid "Number of messages which requires an action" -msgstr "Aantal berichten welke actie vereisen" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_error_counter -msgid "Number of messages with delivery error" -msgstr "Aantal berichten met afleveringsfouten" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread_counter -msgid "Number of unread messages" -msgstr "Aantal ongelezen berichten" - -#. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/account_journal.py:0 -#, python-format -msgid "Online (OCA)" -msgstr "Online (OCA)" - -#. module: account_bank_statement_import_online -#: model:ir.model,name:account_bank_statement_import_online.model_online_bank_statement_provider -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_bank_statement_import_journal_creation__online_bank_statement_provider -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_journal__online_bank_statement_provider -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form -msgid "Online Bank Statement Provider" -msgstr "Online Bank afschrift Aanbieder" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_filter -msgid "Online Bank Statement Providers" -msgstr "Online Bank afschrift Aanbieders" - -#. module: account_bank_statement_import_online -#: code:addons/account_bank_statement_import_online/models/account_journal.py:0 -#: model:ir.model,name:account_bank_statement_import_online.model_online_bank_statement_pull_wizard -#, python-format -msgid "Online Bank Statement Pull Wizard" -msgstr "" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_bank_journal_form -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_journal_form -msgid "Online Bank Statements (OCA)" -msgstr "Online Bank Afschriften (OCA)" - -#. module: account_bank_statement_import_online -#: model:ir.actions.server,name:account_bank_statement_import_online.action_online_bank_statements_pull_wizard -msgid "Online Bank Statements Pull Wizard" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.constraint,message:account_bank_statement_import_online.constraint_online_bank_statement_provider_journal_id_uniq -msgid "Only one online banking statement provider per journal!" -msgstr "" -"Er kan slechts een bankafschrift leverancier worden ingesteld per rekening!" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__origin -msgid "Origin" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__passphrase -msgid "Passphrase" -msgstr "wachtwoordzin" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__password -msgid "Password" -msgstr "Wachtwoord" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_bank_journal_form -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.view_account_journal_form -msgid "Provider" -msgstr "Leverancier" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__provider_ids -msgid "Providers" -msgstr "Leveranciers" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form -msgid "Pull" -msgstr "Opvragen" - -#. module: account_bank_statement_import_online -#: model:ir.actions.server,name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements_ir_actions_server -#: model:ir.cron,cron_name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements -#: model:ir.cron,name:account_bank_statement_import_online.ir_cron_account_pull_online_bank_statements -msgid "Pull Online Bank Statements" -msgstr "Online Bank afschrifte opvragen" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_has_sms_error -msgid "SMS Delivery error" -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__account_number -msgid "Sanitized Account Number" -msgstr "Opgeschoond rekeningnummer" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_provider_form -msgid "Scheduled Pull" -msgstr "Geplande opvraag" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__interval_number -msgid "Scheduled update interval" -msgstr "Opvraag interval" - -#. module: account_bank_statement_import_online -#: model:ir.model.constraint,message:account_bank_statement_import_online.constraint_online_bank_statement_provider_valid_interval_number -msgid "Scheduled update interval must be greater than zero!" -msgstr "Planningsinterval moet groter zijn dan 0!" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__service -msgid "Service" -msgstr "Service" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__date_since -msgid "Since" -msgstr "sinds" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form -msgid "Since (at least)" -msgstr "sinds (ten minste)" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__statement_creation_mode -msgid "Statement Creation Mode" -msgstr "Bankafschrift creatie modus" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_bank_statement_import_journal_creation__online_bank_statement_provider_id -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_account_journal__online_bank_statement_provider_id -msgid "Statement Provider" -msgstr "Afschrift leverancier" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__currency_id -msgid "The currency used to enter statement" -msgstr "De valuta voor het gebruikte afschrift" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__tz -msgid "Timezone" -msgstr "Tijdzone" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__tz -msgid "" -"Timezone to convert transaction timestamps to prior being saved into a " -"statement." -msgstr "" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread -msgid "Unread Messages" -msgstr "Ongelezen berichten" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__message_unread_counter -msgid "Unread Messages Counter" -msgstr "Aantal ongelezen berichten" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_pull_wizard__date_until -msgid "Until" -msgstr "Tot" - -#. module: account_bank_statement_import_online -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online.online_bank_statement_pull_wizard_form -msgid "Until (at least)" -msgstr "Tot (ten minste)" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__update_schedule -msgid "Update Schedule" -msgstr "Update planning" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__username -msgid "Username" -msgstr "Gebruikersnaam" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,field_description:account_bank_statement_import_online.field_online_bank_statement_provider__website_message_ids -msgid "Website Messages" -msgstr "Website berichten" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields,help:account_bank_statement_import_online.field_online_bank_statement_provider__website_message_ids -msgid "Website communication history" -msgstr "Website berichten geschiedenis" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__interval_type__weeks -msgid "Week(s)" -msgstr "Weken" - -#. module: account_bank_statement_import_online -#: model:ir.model.fields.selection,name:account_bank_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__weekly -msgid "Weekly statements" -msgstr "Weekelijkse afschriften" diff --git a/account_bank_statement_import_online/migrations/13.0.1.0.0/noupdate_changes.xml b/account_bank_statement_import_online/migrations/13.0.1.0.0/noupdate_changes.xml deleted file mode 100644 index 55731376..00000000 --- a/account_bank_statement_import_online/migrations/13.0.1.0.0/noupdate_changes.xml +++ /dev/null @@ -1,13 +0,0 @@ - - - - - ['|',('company_id','=',False),('company_id','in',company_ids)] - - diff --git a/account_bank_statement_import_online/migrations/13.0.1.0.0/post-migration.py b/account_bank_statement_import_online/migrations/13.0.1.0.0/post-migration.py deleted file mode 100644 index 88f5a345..00000000 --- a/account_bank_statement_import_online/migrations/13.0.1.0.0/post-migration.py +++ /dev/null @@ -1,14 +0,0 @@ -# Copyright 2020 Brainbean Apps (https://brainbeanapps.com) -# Copyright 2020 Dataplug (https://dataplug.io) -# License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl.html). - -from openupgradelib import openupgrade # pylint: disable=W7936 - - -@openupgrade.migrate() -def migrate(env, version): - openupgrade.load_data( - env.cr, - "account_bank_statement_import_online", - "migrations/13.0.1.0.0/noupdate_changes.xml", - ) diff --git a/account_bank_statement_import_online/views/account_journal.xml b/account_bank_statement_import_online/views/account_journal.xml deleted file mode 100644 index 1759f92c..00000000 --- a/account_bank_statement_import_online/views/account_journal.xml +++ /dev/null @@ -1,132 +0,0 @@ - - - - - account.journal.form - account.journal - - - - - - - - - - account.journal.form - account.journal - - - - - - - - - - account.journal.dashboard.kanban - account.journal - - -
- dashboard.bank_statements_source != 'online_sync' and dashboard.bank_statements_source != 'online' -
- - dashboard.bank_statements_source != 'online_sync' and dashboard.bank_statements_source != 'online' - - - dashboard.bank_statements_source != 'online_sync' and dashboard.bank_statements_source != 'online' - -
-
- - Online Bank Statements Pull Wizard - ir.actions.server - - - code - - if records: - action = records.action_online_bank_statements_pull_wizard() - - -
diff --git a/account_bank_statement_import_online_ponto/i18n/account_bank_statement_import_online_ponto.pot b/account_bank_statement_import_online_ponto/i18n/account_bank_statement_import_online_ponto.pot deleted file mode 100644 index 2dc153e6..00000000 --- a/account_bank_statement_import_online_ponto/i18n/account_bank_statement_import_online_ponto.pot +++ /dev/null @@ -1,97 +0,0 @@ -# Translation of Odoo Server. -# This file contains the translation of the following modules: -# * account_bank_statement_import_online_ponto -# -msgid "" -msgstr "" -"Project-Id-Version: Odoo Server 13.0\n" -"Report-Msgid-Bugs-To: \n" -"Last-Translator: \n" -"Language-Team: \n" -"MIME-Version: 1.0\n" -"Content-Type: text/plain; charset=UTF-8\n" -"Content-Transfer-Encoding: \n" -"Plural-Forms: \n" - -#. module: account_bank_statement_import_online_ponto -#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 -#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 -#, python-format -msgid "" -"%s \n" -"\n" -" %s" -msgstr "" - -#. module: account_bank_statement_import_online_ponto -#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 -#, python-format -msgid "" -"Error during Create Synchronisation %s \n" -"\n" -" %s" -msgstr "" - -#. module: account_bank_statement_import_online_ponto -#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 -#, python-format -msgid "" -"Error during get transaction.\n" -"\n" -"%s \n" -"\n" -" %s" -msgstr "" - -#. module: account_bank_statement_import_online_ponto -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online_ponto.online_bank_statement_provider_form -msgid "Login" -msgstr "" - -#. module: account_bank_statement_import_online_ponto -#: model:ir.model,name:account_bank_statement_import_online_ponto.model_online_bank_statement_provider -msgid "Online Bank Statement Provider" -msgstr "" - -#. module: account_bank_statement_import_online_ponto -#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 -#, python-format -msgid "Please fill login and key." -msgstr "" - -#. module: account_bank_statement_import_online_ponto -#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 -#, python-format -msgid "Ponto : no token" -msgstr "" - -#. module: account_bank_statement_import_online_ponto -#: code:addons/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 -#, python-format -msgid "Ponto : wrong configuration, unknow account %s" -msgstr "" - -#. module: account_bank_statement_import_online_ponto -#: model:ir.model.fields,field_description:account_bank_statement_import_online_ponto.field_online_bank_statement_provider__ponto_last_identifier -msgid "Ponto Last Identifier" -msgstr "" - -#. module: account_bank_statement_import_online_ponto -#: model:ir.model.fields,field_description:account_bank_statement_import_online_ponto.field_online_bank_statement_provider__ponto_token -msgid "Ponto Token" -msgstr "" - -#. module: account_bank_statement_import_online_ponto -#: model:ir.model.fields,field_description:account_bank_statement_import_online_ponto.field_online_bank_statement_provider__ponto_token_expiration -msgid "Ponto Token Expiration" -msgstr "" - -#. module: account_bank_statement_import_online_ponto -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online_ponto.online_bank_statement_provider_form -msgid "Reset Last identifier." -msgstr "" - -#. module: account_bank_statement_import_online_ponto -#: model_terms:ir.ui.view,arch_db:account_bank_statement_import_online_ponto.online_bank_statement_provider_form -msgid "Secret Key" -msgstr "" diff --git a/account_bank_statement_import_online/README.rst b/account_statement_import_online/README.rst similarity index 87% rename from account_bank_statement_import_online/README.rst rename to account_statement_import_online/README.rst index e37468d6..3e610e90 100644 --- a/account_bank_statement_import_online/README.rst +++ b/account_statement_import_online/README.rst @@ -14,13 +14,13 @@ Online Bank Statements :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fbank--statement--import-lightgray.png?logo=github - :target: https://github.com/OCA/bank-statement-import/tree/13.0/account_bank_statement_import_online + :target: https://github.com/OCA/bank-statement-import/tree/14.0/account_statement_import_online :alt: OCA/bank-statement-import .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png - :target: https://translation.odoo-community.org/projects/bank-statement-import-13-0/bank-statement-import-13-0-account_bank_statement_import_online + :target: https://translation.odoo-community.org/projects/bank-statement-import-14-0/bank-statement-import-14-0-account_statement_import_online :alt: Translate me on Weblate .. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png - :target: https://runbot.odoo-community.org/runbot/174/13.0 + :target: https://runbot.odoo-community.org/runbot/174/14.0 :alt: Try me on Runbot |badge1| |badge2| |badge3| |badge4| |badge5| @@ -78,7 +78,7 @@ Bug Tracker Bugs are tracked on `GitHub 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 `_. +`feedback `_. Do not contact contributors directly about support or help with technical issues. @@ -97,6 +97,10 @@ Contributors * Alexey Pelykh +* `Therp BV `__ + + * Ronald Portier + Maintainers ~~~~~~~~~~~ @@ -118,6 +122,6 @@ Current `maintainer `__: |maintainer-alexey-pelykh| -This module is part of the `OCA/bank-statement-import `_ project on GitHub. +This module is part of the `OCA/bank-statement-import `_ project on GitHub. You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/account_bank_statement_import_online/__init__.py b/account_statement_import_online/__init__.py similarity index 100% rename from account_bank_statement_import_online/__init__.py rename to account_statement_import_online/__init__.py diff --git a/account_bank_statement_import_online/__manifest__.py b/account_statement_import_online/__manifest__.py similarity index 87% rename from account_bank_statement_import_online/__manifest__.py rename to account_statement_import_online/__manifest__.py index e0de7e07..1fcfa9ee 100644 --- a/account_bank_statement_import_online/__manifest__.py +++ b/account_statement_import_online/__manifest__.py @@ -4,7 +4,7 @@ { "name": "Online Bank Statements", - "version": "13.0.1.0.0", + "version": "14.0.1.0.0", "author": "CorporateHub, Odoo Community Association (OCA)", "maintainers": ["alexey-pelykh"], "website": "https://github.com/OCA/bank-statement-import", @@ -13,11 +13,11 @@ "summary": "Online bank statements update", "depends": [ "account", - "account_bank_statement_import", + "account_statement_import", "web_widget_dropdown_dynamic", ], "data": [ - "data/account_bank_statement_import_online.xml", + "data/account_statement_import_online.xml", "security/ir.model.access.csv", "security/online_bank_statement_provider.xml", "views/account_journal.xml", diff --git a/account_bank_statement_import_online/data/account_bank_statement_import_online.xml b/account_statement_import_online/data/account_statement_import_online.xml similarity index 89% rename from account_bank_statement_import_online/data/account_bank_statement_import_online.xml rename to account_statement_import_online/data/account_statement_import_online.xml index 269398af..3df898e4 100644 --- a/account_bank_statement_import_online/data/account_bank_statement_import_online.xml +++ b/account_statement_import_online/data/account_statement_import_online.xml @@ -15,7 +15,7 @@ model._scheduled_pull() diff --git a/account_statement_import_online/i18n/account_statement_import_online.pot b/account_statement_import_online/i18n/account_statement_import_online.pot new file mode 100644 index 00000000..4bb755e0 --- /dev/null +++ b/account_statement_import_online/i18n/account_statement_import_online.pot @@ -0,0 +1,485 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * account_statement_import_online +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 13.0\n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: \n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: account_statement_import_online +#: code:addons/account_statement_import_online/models/online_bank_statement_provider.py:0 +#, python-format +msgid "%(number)s %(type)s" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_needaction +msgid "Action Needed" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__active +msgid "Active" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__api_base +msgid "Api Base" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_attachment_count +msgid "Attachment Count" +msgstr "" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Cancel" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__certificate +msgid "Certificate" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__certificate_chain +msgid "Certificate Chain" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__certificate_private_key +msgid "Certificate Private Key" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__certificate_public_key +msgid "Certificate Public Key" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__company_id +msgid "Company" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__company_id +msgid "Company related to this journal" +msgstr "" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_provider_form +msgid "Configuration" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__create_uid +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__create_uid +msgid "Created by" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__create_date +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__create_date +msgid "Created on" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__currency_id +msgid "Currency" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields.selection,name:account_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__daily +msgid "Daily statements" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields.selection,name:account_statement_import_online.selection__online_bank_statement_provider__interval_type__days +msgid "Day(s)" +msgstr "" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_provider_form +msgid "Details" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__display_name +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__display_name +msgid "Display Name" +msgstr "" + +#. module: account_statement_import_online +#: code:addons/account_statement_import_online/models/online_bank_statement_provider.py:0 +#, python-format +msgid "" +"Failed to obtain statement data for period since %s until %s: %s. See server" +" logs for more details." +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_follower_ids +msgid "Followers" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_channel_ids +msgid "Followers (Channels)" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_partner_ids +msgid "Followers (Partners)" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields.selection,name:account_statement_import_online.selection__online_bank_statement_provider__interval_type__hours +msgid "Hour(s)" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__id +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__id +msgid "ID" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__message_needaction +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__message_unread +msgid "If checked, new messages require your attention." +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__message_has_error +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__message_has_sms_error +msgid "If checked, some messages have a delivery error." +msgstr "" + +#. module: account_statement_import_online +#: code:addons/account_statement_import_online/models/online_bank_statement_provider.py:0 +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_provider_filter +#, python-format +msgid "Inactive" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__interval_type +msgid "Interval Type" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_is_follower +msgid "Is Follower" +msgstr "" + +#. module: account_statement_import_online +#: code:addons/account_statement_import_online/models/online_bank_statement_provider.py:0 +#, python-format +msgid "Issue with Online Bank Statement Provider" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model,name:account_statement_import_online.model_account_journal +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__journal_id +msgid "Journal" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__key +msgid "Key" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider____last_update +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard____last_update +msgid "Last Modified on" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__write_uid +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__write_uid +msgid "Last Updated by" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__write_date +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__write_date +msgid "Last Updated on" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__last_successful_run +msgid "Last successful pull" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_main_attachment_id +msgid "Main Attachment" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_has_error +msgid "Message Delivery error" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_ids +msgid "Messages" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields.selection,name:account_statement_import_online.selection__online_bank_statement_provider__interval_type__minutes +msgid "Minute(s)" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields.selection,name:account_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__monthly +msgid "Monthly statements" +msgstr "" + +#. module: account_statement_import_online +#: code:addons/account_statement_import_online/models/online_bank_statement_provider.py:0 +#, python-format +msgid "N/A" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__name +msgid "Name" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__next_run +msgid "Next scheduled pull" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_needaction_counter +msgid "Number of Actions" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_has_error_counter +msgid "Number of errors" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__message_needaction_counter +msgid "Number of messages which requires an action" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__message_has_error_counter +msgid "Number of messages with delivery error" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__message_unread_counter +msgid "Number of unread messages" +msgstr "" + +#. module: account_statement_import_online +#: code:addons/account_statement_import_online/models/account_journal.py:0 +#, python-format +msgid "Online (OCA)" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model,name:account_statement_import_online.model_online_bank_statement_provider +#: model:ir.model.fields,field_description:account_statement_import_online.field_account_statement_import_journal_creation__online_bank_statement_provider +#: model:ir.model.fields,field_description:account_statement_import_online.field_account_journal__online_bank_statement_provider +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_provider_form +msgid "Online Bank Statement Provider" +msgstr "" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_provider_filter +msgid "Online Bank Statement Providers" +msgstr "" + +#. module: account_statement_import_online +#: code:addons/account_statement_import_online/models/account_journal.py:0 +#: model:ir.model,name:account_statement_import_online.model_online_bank_statement_pull_wizard +#, python-format +msgid "Online Bank Statement Pull Wizard" +msgstr "" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.view_account_bank_journal_form +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.view_account_journal_form +msgid "Online Bank Statements (OCA)" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.actions.server,name:account_statement_import_online.action_online_bank_statements_pull_wizard +msgid "Online Bank Statements Pull Wizard" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.constraint,message:account_statement_import_online.constraint_online_bank_statement_provider_journal_id_uniq +msgid "Only one online banking statement provider per journal!" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__origin +msgid "Origin" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__passphrase +msgid "Passphrase" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__password +msgid "Password" +msgstr "" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.view_account_bank_journal_form +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.view_account_journal_form +msgid "Provider" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__provider_ids +msgid "Providers" +msgstr "" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Pull" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.actions.server,name:account_statement_import_online.ir_cron_account_pull_online_bank_statements_ir_actions_server +#: model:ir.cron,cron_name:account_statement_import_online.ir_cron_account_pull_online_bank_statements +#: model:ir.cron,name:account_statement_import_online.ir_cron_account_pull_online_bank_statements +msgid "Pull Online Bank Statements" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_has_sms_error +msgid "SMS Delivery error" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__account_number +msgid "Sanitized Account Number" +msgstr "" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_provider_form +msgid "Scheduled Pull" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__interval_number +msgid "Scheduled update interval" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.constraint,message:account_statement_import_online.constraint_online_bank_statement_provider_valid_interval_number +msgid "Scheduled update interval must be greater than zero!" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__service +msgid "Service" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__date_since +msgid "Since" +msgstr "" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Since (at least)" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__statement_creation_mode +msgid "Statement Creation Mode" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_account_statement_import_journal_creation__online_bank_statement_provider_id +#: model:ir.model.fields,field_description:account_statement_import_online.field_account_journal__online_bank_statement_provider_id +msgid "Statement Provider" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__currency_id +msgid "The currency used to enter statement" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__tz +msgid "Timezone" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__tz +msgid "" +"Timezone to convert transaction timestamps to prior being saved into a " +"statement." +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_unread +msgid "Unread Messages" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_unread_counter +msgid "Unread Messages Counter" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__date_until +msgid "Until" +msgstr "" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Until (at least)" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__update_schedule +msgid "Update Schedule" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__username +msgid "Username" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__website_message_ids +msgid "Website Messages" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__website_message_ids +msgid "Website communication history" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields.selection,name:account_statement_import_online.selection__online_bank_statement_provider__interval_type__weeks +msgid "Week(s)" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields.selection,name:account_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__weekly +msgid "Weekly statements" +msgstr "" diff --git a/account_statement_import_online/i18n/nl.po b/account_statement_import_online/i18n/nl.po new file mode 100644 index 00000000..ae12ef32 --- /dev/null +++ b/account_statement_import_online/i18n/nl.po @@ -0,0 +1,491 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * account_statement_import_online +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 13.0\n" +"Report-Msgid-Bugs-To: \n" +"PO-Revision-Date: 2021-04-23 18:47+0000\n" +"Last-Translator: Bosd \n" +"Language-Team: none\n" +"Language: nl\n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: nplurals=2; plural=n != 1;\n" +"X-Generator: Weblate 4.3.2\n" + +#. module: account_statement_import_online +#: code:addons/account_statement_import_online/models/online_bank_statement_provider.py:0 +#, python-format +msgid "%(number)s %(type)s" +msgstr "%(number)s %(type)s" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_needaction +msgid "Action Needed" +msgstr "Actie vereist" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__active +msgid "Active" +msgstr "Actief" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__api_base +msgid "Api Base" +msgstr "Api Base" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_attachment_count +msgid "Attachment Count" +msgstr "Aantal Bijlagen" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Cancel" +msgstr "Annuleer" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__certificate +msgid "Certificate" +msgstr "Certificaat" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__certificate_chain +msgid "Certificate Chain" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__certificate_private_key +msgid "Certificate Private Key" +msgstr "Certificaat privé sleutel" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__certificate_public_key +msgid "Certificate Public Key" +msgstr "Certificaat publieke sleutel" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__company_id +msgid "Company" +msgstr "Bedrijf" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__company_id +msgid "Company related to this journal" +msgstr "Bedrijf gerelateerd aan dit dagboek" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_provider_form +msgid "Configuration" +msgstr "Configuratie" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__create_uid +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__create_uid +msgid "Created by" +msgstr "Aangemaakt door" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__create_date +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__create_date +msgid "Created on" +msgstr "Aangemaakt op" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__currency_id +msgid "Currency" +msgstr "Valuta" + +#. module: account_statement_import_online +#: model:ir.model.fields.selection,name:account_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__daily +msgid "Daily statements" +msgstr "Dagelijks afschrift" + +#. module: account_statement_import_online +#: model:ir.model.fields.selection,name:account_statement_import_online.selection__online_bank_statement_provider__interval_type__days +msgid "Day(s)" +msgstr "Dag(en)" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_provider_form +msgid "Details" +msgstr "Details" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__display_name +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__display_name +msgid "Display Name" +msgstr "Weergavenaam" + +#. module: account_statement_import_online +#: code:addons/account_statement_import_online/models/online_bank_statement_provider.py:0 +#, python-format +msgid "" +"Failed to obtain statement data for period since %s until %s: %s. See server" +" logs for more details." +msgstr "" +"Kon de afschriften niet verkrijgen voor de periode van %s tot %s:%s. Bekijk " +"de error log van de server voor details." + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_follower_ids +msgid "Followers" +msgstr "Volgers" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_channel_ids +msgid "Followers (Channels)" +msgstr "Volgers (Kanalen)" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_partner_ids +msgid "Followers (Partners)" +msgstr "Volgers (Partners)" + +#. module: account_statement_import_online +#: model:ir.model.fields.selection,name:account_statement_import_online.selection__online_bank_statement_provider__interval_type__hours +msgid "Hour(s)" +msgstr "Uur/Uren" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__id +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__id +msgid "ID" +msgstr "ID" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__message_needaction +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__message_unread +msgid "If checked, new messages require your attention." +msgstr "Indien aangevinkt, nieuwe berichten vereisen uw aandacht." + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__message_has_error +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__message_has_sms_error +msgid "If checked, some messages have a delivery error." +msgstr "Indien aangevinkt, sommige berichten hebben een foutmelding." + +#. module: account_statement_import_online +#: code:addons/account_statement_import_online/models/online_bank_statement_provider.py:0 +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_provider_filter +#, python-format +msgid "Inactive" +msgstr "inactief" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__interval_type +msgid "Interval Type" +msgstr "Interval Type" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_is_follower +msgid "Is Follower" +msgstr "Is volger" + +#. module: account_statement_import_online +#: code:addons/account_statement_import_online/models/online_bank_statement_provider.py:0 +#, python-format +msgid "Issue with Online Bank Statement Provider" +msgstr "Probleem met Online Bank afschrift leverancier" + +#. module: account_statement_import_online +#: model:ir.model,name:account_statement_import_online.model_account_journal +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__journal_id +msgid "Journal" +msgstr "Dagboek" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__key +msgid "Key" +msgstr "Sleutel" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider____last_update +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard____last_update +msgid "Last Modified on" +msgstr "Laatst bijgewerkt op" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__write_uid +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__write_uid +msgid "Last Updated by" +msgstr "Laatst bijgewerkt door" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__write_date +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__write_date +msgid "Last Updated on" +msgstr "Laatst bijgewerkt op" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__last_successful_run +msgid "Last successful pull" +msgstr "Laatst succesvolle opvraag" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_main_attachment_id +msgid "Main Attachment" +msgstr "Hoofdbijlage" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_has_error +msgid "Message Delivery error" +msgstr "Berichtafleverinsfout" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_ids +msgid "Messages" +msgstr "Berichten" + +#. module: account_statement_import_online +#: model:ir.model.fields.selection,name:account_statement_import_online.selection__online_bank_statement_provider__interval_type__minutes +msgid "Minute(s)" +msgstr "Minuut/Minuten" + +#. module: account_statement_import_online +#: model:ir.model.fields.selection,name:account_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__monthly +msgid "Monthly statements" +msgstr "Maandelijkse afschriften" + +#. module: account_statement_import_online +#: code:addons/account_statement_import_online/models/online_bank_statement_provider.py:0 +#, python-format +msgid "N/A" +msgstr "N.V.T." + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__name +msgid "Name" +msgstr "Naam" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__next_run +msgid "Next scheduled pull" +msgstr "Volgende geplande opvraag" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_needaction_counter +msgid "Number of Actions" +msgstr "Aantal acties" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_has_error_counter +msgid "Number of errors" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__message_needaction_counter +msgid "Number of messages which requires an action" +msgstr "Aantal berichten welke actie vereisen" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__message_has_error_counter +msgid "Number of messages with delivery error" +msgstr "Aantal berichten met afleveringsfouten" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__message_unread_counter +msgid "Number of unread messages" +msgstr "Aantal ongelezen berichten" + +#. module: account_statement_import_online +#: code:addons/account_statement_import_online/models/account_journal.py:0 +#, python-format +msgid "Online (OCA)" +msgstr "Online (OCA)" + +#. module: account_statement_import_online +#: model:ir.model,name:account_statement_import_online.model_online_bank_statement_provider +#: model:ir.model.fields,field_description:account_statement_import_online.field_account_statement_import_journal_creation__online_bank_statement_provider +#: model:ir.model.fields,field_description:account_statement_import_online.field_account_journal__online_bank_statement_provider +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_provider_form +msgid "Online Bank Statement Provider" +msgstr "Online Bank afschrift Aanbieder" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_provider_filter +msgid "Online Bank Statement Providers" +msgstr "Online Bank afschrift Aanbieders" + +#. module: account_statement_import_online +#: code:addons/account_statement_import_online/models/account_journal.py:0 +#: model:ir.model,name:account_statement_import_online.model_online_bank_statement_pull_wizard +#, python-format +msgid "Online Bank Statement Pull Wizard" +msgstr "" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.view_account_bank_journal_form +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.view_account_journal_form +msgid "Online Bank Statements (OCA)" +msgstr "Online Bank Afschriften (OCA)" + +#. module: account_statement_import_online +#: model:ir.actions.server,name:account_statement_import_online.action_online_bank_statements_pull_wizard +msgid "Online Bank Statements Pull Wizard" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.constraint,message:account_statement_import_online.constraint_online_bank_statement_provider_journal_id_uniq +msgid "Only one online banking statement provider per journal!" +msgstr "" +"Er kan slechts een bankafschrift leverancier worden ingesteld per rekening!" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__origin +msgid "Origin" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__passphrase +msgid "Passphrase" +msgstr "wachtwoordzin" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__password +msgid "Password" +msgstr "Wachtwoord" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.view_account_bank_journal_form +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.view_account_journal_form +msgid "Provider" +msgstr "Leverancier" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__provider_ids +msgid "Providers" +msgstr "Leveranciers" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Pull" +msgstr "Opvragen" + +#. module: account_statement_import_online +#: model:ir.actions.server,name:account_statement_import_online.ir_cron_account_pull_online_bank_statements_ir_actions_server +#: model:ir.cron,cron_name:account_statement_import_online.ir_cron_account_pull_online_bank_statements +#: model:ir.cron,name:account_statement_import_online.ir_cron_account_pull_online_bank_statements +msgid "Pull Online Bank Statements" +msgstr "Online Bank afschrifte opvragen" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_has_sms_error +msgid "SMS Delivery error" +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__account_number +msgid "Sanitized Account Number" +msgstr "Opgeschoond rekeningnummer" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_provider_form +msgid "Scheduled Pull" +msgstr "Geplande opvraag" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__interval_number +msgid "Scheduled update interval" +msgstr "Opvraag interval" + +#. module: account_statement_import_online +#: model:ir.model.constraint,message:account_statement_import_online.constraint_online_bank_statement_provider_valid_interval_number +msgid "Scheduled update interval must be greater than zero!" +msgstr "Planningsinterval moet groter zijn dan 0!" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__service +msgid "Service" +msgstr "Service" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__date_since +msgid "Since" +msgstr "sinds" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Since (at least)" +msgstr "sinds (ten minste)" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__statement_creation_mode +msgid "Statement Creation Mode" +msgstr "Bankafschrift creatie modus" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_account_statement_import_journal_creation__online_bank_statement_provider_id +#: model:ir.model.fields,field_description:account_statement_import_online.field_account_journal__online_bank_statement_provider_id +msgid "Statement Provider" +msgstr "Afschrift leverancier" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__currency_id +msgid "The currency used to enter statement" +msgstr "De valuta voor het gebruikte afschrift" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__tz +msgid "Timezone" +msgstr "Tijdzone" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__tz +msgid "" +"Timezone to convert transaction timestamps to prior being saved into a " +"statement." +msgstr "" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_unread +msgid "Unread Messages" +msgstr "Ongelezen berichten" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__message_unread_counter +msgid "Unread Messages Counter" +msgstr "Aantal ongelezen berichten" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_pull_wizard__date_until +msgid "Until" +msgstr "Tot" + +#. module: account_statement_import_online +#: model_terms:ir.ui.view,arch_db:account_statement_import_online.online_bank_statement_pull_wizard_form +msgid "Until (at least)" +msgstr "Tot (ten minste)" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__update_schedule +msgid "Update Schedule" +msgstr "Update planning" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__username +msgid "Username" +msgstr "Gebruikersnaam" + +#. module: account_statement_import_online +#: model:ir.model.fields,field_description:account_statement_import_online.field_online_bank_statement_provider__website_message_ids +msgid "Website Messages" +msgstr "Website berichten" + +#. module: account_statement_import_online +#: model:ir.model.fields,help:account_statement_import_online.field_online_bank_statement_provider__website_message_ids +msgid "Website communication history" +msgstr "Website berichten geschiedenis" + +#. module: account_statement_import_online +#: model:ir.model.fields.selection,name:account_statement_import_online.selection__online_bank_statement_provider__interval_type__weeks +msgid "Week(s)" +msgstr "Weken" + +#. module: account_statement_import_online +#: model:ir.model.fields.selection,name:account_statement_import_online.selection__online_bank_statement_provider__statement_creation_mode__weekly +msgid "Weekly statements" +msgstr "Weekelijkse afschriften" diff --git a/account_bank_statement_import_online/models/__init__.py b/account_statement_import_online/models/__init__.py similarity index 100% rename from account_bank_statement_import_online/models/__init__.py rename to account_statement_import_online/models/__init__.py diff --git a/account_bank_statement_import_online/models/account_journal.py b/account_statement_import_online/models/account_journal.py similarity index 100% rename from account_bank_statement_import_online/models/account_journal.py rename to account_statement_import_online/models/account_journal.py diff --git a/account_bank_statement_import_online/models/online_bank_statement_provider.py b/account_statement_import_online/models/online_bank_statement_provider.py similarity index 70% rename from account_bank_statement_import_online/models/online_bank_statement_provider.py rename to account_statement_import_online/models/online_bank_statement_provider.py index 85776a1d..63ffb315 100644 --- a/account_bank_statement_import_online/models/online_bank_statement_provider.py +++ b/account_statement_import_online/models/online_bank_statement_provider.py @@ -10,7 +10,7 @@ from html import escape from dateutil.relativedelta import MO, relativedelta from pytz import timezone, utc -from odoo import SUPERUSER_ID, _, api, fields, models +from odoo import _, api, fields, models from odoo.addons.base.models.res_bank import sanitize_account_number from odoo.addons.base.models.res_partner import _tz_get @@ -146,16 +146,9 @@ class OnlineBankStatementProvider(models.Model): )[0][1], } - def _pull(self, date_since, date_until): # noqa: C901 - AccountBankStatement = self.env["account.bank.statement"] + def _pull(self, date_since, date_until): is_scheduled = self.env.context.get("scheduled") - if is_scheduled: - AccountBankStatement = AccountBankStatement.with_context( - tracking_disable=True, - ) - AccountBankStatementLine = self.env["account.bank.statement.line"] for provider in self: - provider_tz = timezone(provider.tz) if provider.tz else utc statement_date_since = provider._get_statement_date_since(date_since) while statement_date_since < date_until: statement_date_until = ( @@ -192,108 +185,121 @@ class OnlineBankStatementProvider(models.Model): ) break raise - statement_date = provider._get_statement_date( - statement_date_since, - statement_date_until, + provider._create_or_update_statement( + data, statement_date_since, statement_date_until ) - if not data: - data = ([], {}) - lines_data, statement_values = data - if not lines_data: - lines_data = [] - if not statement_values: - statement_values = {} - statement = AccountBankStatement.search( - [ - ("journal_id", "=", provider.journal_id.id), - ("state", "=", "open"), - ("date", "=", statement_date), - ], - limit=1, - ) - if not statement: - statement_values.update( - { - "name": provider.journal_id.sequence_id.with_context( - ir_sequence_date=statement_date, - ).next_by_id(), - "journal_id": provider.journal_id.id, - "date": statement_date, - } - ) - statement = AccountBankStatement.with_context( - journal_id=provider.journal_id.id, - ).create( - # NOTE: This is needed since create() alters values - statement_values.copy() - ) - filtered_lines = [] - for line_values in lines_data: - date = line_values["date"] - if not isinstance(date, datetime): - date = fields.Datetime.from_string(date) - - if date.tzinfo is None: - date = date.replace(tzinfo=utc) - date = date.astimezone(utc).replace(tzinfo=None) - - if date < statement_date_since: - if "balance_start" in statement_values: - statement_values["balance_start"] = Decimal( - statement_values["balance_start"] - ) + Decimal(line_values["amount"]) - continue - elif date >= statement_date_until: - if "balance_end_real" in statement_values: - statement_values["balance_end_real"] = Decimal( - statement_values["balance_end_real"] - ) - Decimal(line_values["amount"]) - continue - - date = date.replace(tzinfo=utc) - date = date.astimezone(provider_tz).replace(tzinfo=None) - line_values["date"] = date - - unique_import_id = line_values.get("unique_import_id") - if unique_import_id: - unique_import_id = provider._generate_unique_import_id( - unique_import_id - ) - line_values.update({"unique_import_id": unique_import_id}) - if AccountBankStatementLine.with_user(SUPERUSER_ID).search( - [("unique_import_id", "=", unique_import_id)], limit=1 - ): - continue - - bank_account_number = line_values.get("account_number") - if bank_account_number: - line_values.update( - { - "account_number": ( - self._sanitize_bank_account_number( - bank_account_number - ) - ), - } - ) - - filtered_lines.append(line_values) - statement_values.update( - {"line_ids": [[0, False, line] for line in filtered_lines]} - ) - if "balance_start" in statement_values: - statement_values["balance_start"] = float( - statement_values["balance_start"] - ) - if "balance_end_real" in statement_values: - statement_values["balance_end_real"] = float( - statement_values["balance_end_real"] - ) - statement.write(statement_values) statement_date_since = statement_date_until if is_scheduled: provider._schedule_next_run() + def _create_or_update_statement( + self, data, statement_date_since, statement_date_until + ): + """Create or update bank statement with the data retrieved from provider.""" + self.ensure_one() + AccountBankStatement = self.env["account.bank.statement"] + is_scheduled = self.env.context.get("scheduled") + if is_scheduled: + AccountBankStatement = AccountBankStatement.with_context( + tracking_disable=True, + ) + if not data: + data = ([], {}) + lines_data, statement_values = data + if not lines_data: + lines_data = [] + if not statement_values: + statement_values = {} + statement_date = self._get_statement_date( + statement_date_since, + statement_date_until, + ) + statement = AccountBankStatement.search( + [ + ("journal_id", "=", self.journal_id.id), + ("state", "=", "open"), + ("date", "=", statement_date), + ], + limit=1, + ) + if not statement: + statement_values.update( + { + "name": "%s/%s" + % (self.journal_id.code, statement_date.strftime("%Y-%m-%d")), + "journal_id": self.journal_id.id, + "date": statement_date, + } + ) + statement = AccountBankStatement.with_context( + journal_id=self.journal_id.id, + ).create( + # NOTE: This is needed since create() alters values + statement_values.copy() + ) + filtered_lines = self._get_statement_filtered_lines( + lines_data, statement_values, statement_date_since, statement_date_until + ) + statement_values.update( + {"line_ids": [[0, False, line] for line in filtered_lines]} + ) + if "balance_start" in statement_values: + statement_values["balance_start"] = float(statement_values["balance_start"]) + if "balance_end_real" in statement_values: + statement_values["balance_end_real"] = float( + statement_values["balance_end_real"] + ) + statement.write(statement_values) + + def _get_statement_filtered_lines( + self, lines_data, statement_values, statement_date_since, statement_date_until + ): + """Get lines from line data, but only for the right date.""" + AccountBankStatementLine = self.env["account.bank.statement.line"] + provider_tz = timezone(self.tz) if self.tz else utc + filtered_lines = [] + for line_values in lines_data: + date = line_values["date"] + if not isinstance(date, datetime): + date = fields.Datetime.from_string(date) + if date.tzinfo is None: + date = date.replace(tzinfo=utc) + date = date.astimezone(utc).replace(tzinfo=None) + if date < statement_date_since: + if "balance_start" in statement_values: + statement_values["balance_start"] = Decimal( + statement_values["balance_start"] + ) + Decimal(line_values["amount"]) + continue + elif date >= statement_date_until: + if "balance_end_real" in statement_values: + statement_values["balance_end_real"] = Decimal( + statement_values["balance_end_real"] + ) - Decimal(line_values["amount"]) + continue + date = date.replace(tzinfo=utc) + date = date.astimezone(provider_tz).replace(tzinfo=None) + line_values["date"] = date + unique_import_id = line_values.get("unique_import_id") + if unique_import_id: + unique_import_id = self._generate_unique_import_id(unique_import_id) + line_values.update({"unique_import_id": unique_import_id}) + if AccountBankStatementLine.sudo().search( + [("unique_import_id", "=", unique_import_id)], limit=1 + ): + continue + bank_account_number = line_values.get("account_number") + if bank_account_number: + line_values.update( + { + "account_number": ( + self._sanitize_bank_account_number(bank_account_number) + ), + } + ) + filtered_lines.append(line_values) + return filtered_lines + def _schedule_next_run(self): self.ensure_one() self.last_successful_run = self.next_run diff --git a/account_bank_statement_import_online/readme/CONFIGURE.rst b/account_statement_import_online/readme/CONFIGURE.rst similarity index 100% rename from account_bank_statement_import_online/readme/CONFIGURE.rst rename to account_statement_import_online/readme/CONFIGURE.rst diff --git a/account_bank_statement_import_online/readme/CONTRIBUTORS.rst b/account_statement_import_online/readme/CONTRIBUTORS.rst similarity index 55% rename from account_bank_statement_import_online/readme/CONTRIBUTORS.rst rename to account_statement_import_online/readme/CONTRIBUTORS.rst index 724bc1d0..fc2a1a3c 100644 --- a/account_bank_statement_import_online/readme/CONTRIBUTORS.rst +++ b/account_statement_import_online/readme/CONTRIBUTORS.rst @@ -1,3 +1,7 @@ * `CorporateHub `__ * Alexey Pelykh + +* `Therp BV `__ + + * Ronald Portier diff --git a/account_bank_statement_import_online/readme/DESCRIPTION.rst b/account_statement_import_online/readme/DESCRIPTION.rst similarity index 100% rename from account_bank_statement_import_online/readme/DESCRIPTION.rst rename to account_statement_import_online/readme/DESCRIPTION.rst diff --git a/account_bank_statement_import_online/readme/USAGE.rst b/account_statement_import_online/readme/USAGE.rst similarity index 100% rename from account_bank_statement_import_online/readme/USAGE.rst rename to account_statement_import_online/readme/USAGE.rst diff --git a/account_bank_statement_import_online/security/ir.model.access.csv b/account_statement_import_online/security/ir.model.access.csv similarity index 69% rename from account_bank_statement_import_online/security/ir.model.access.csv rename to account_statement_import_online/security/ir.model.access.csv index 4e04821b..d0856372 100644 --- a/account_bank_statement_import_online/security/ir.model.access.csv +++ b/account_statement_import_online/security/ir.model.access.csv @@ -1,3 +1,4 @@ id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink access_online_bank_statement_provider_admin,online.bank.statement.provider:base.group_system,model_online_bank_statement_provider,base.group_system,1,1,1,1 access_online_bank_statement_provider_user,online.bank.statement.provider:account.group_account_user,model_online_bank_statement_provider,account.group_account_user,1,1,1,1 +access_online_bank_statement_pull_wizard_user,online.bank.statement.pull.wizard:account.group_account_user,model_online_bank_statement_pull_wizard,account.group_account_user,1,1,1,1 diff --git a/account_bank_statement_import_online/security/online_bank_statement_provider.xml b/account_statement_import_online/security/online_bank_statement_provider.xml similarity index 100% rename from account_bank_statement_import_online/security/online_bank_statement_provider.xml rename to account_statement_import_online/security/online_bank_statement_provider.xml diff --git a/account_bank_statement_import_online/static/description/icon.png b/account_statement_import_online/static/description/icon.png similarity index 100% rename from account_bank_statement_import_online/static/description/icon.png rename to account_statement_import_online/static/description/icon.png diff --git a/account_bank_statement_import_online/static/description/index.html b/account_statement_import_online/static/description/index.html similarity index 91% rename from account_bank_statement_import_online/static/description/index.html rename to account_statement_import_online/static/description/index.html index 021525c7..5a9a78fe 100644 --- a/account_bank_statement_import_online/static/description/index.html +++ b/account_statement_import_online/static/description/index.html @@ -367,7 +367,7 @@ ul.auto-toc { !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> -

Beta License: AGPL-3 OCA/bank-statement-import Translate me on Weblate Try me on Runbot

+

Beta License: AGPL-3 OCA/bank-statement-import Translate me on Weblate Try me on Runbot

This module provides base for building online bank statements providers.

Table of contents

@@ -426,7 +426,7 @@ section

Bugs are tracked on GitHub 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.

+feedback.

Do not contact contributors directly about support or help with technical issues.

@@ -444,6 +444,10 @@ If you spotted it first, help us smashing it by providing a detailed and welcome
  • Alexey Pelykh <alexey.pelykh@corphub.eu>
  • +
  • Therp BV +
  • @@ -455,7 +459,7 @@ mission is to support the collaborative development of Odoo features and promote its widespread use.

    Current maintainer:

    alexey-pelykh

    -

    This module is part of the OCA/bank-statement-import project on GitHub.

    +

    This module is part of the OCA/bank-statement-import project on GitHub.

    You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

    diff --git a/account_bank_statement_import_online/tests/__init__.py b/account_statement_import_online/tests/__init__.py similarity index 100% rename from account_bank_statement_import_online/tests/__init__.py rename to account_statement_import_online/tests/__init__.py diff --git a/account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py b/account_statement_import_online/tests/online_bank_statement_provider_dummy.py similarity index 100% rename from account_bank_statement_import_online/tests/online_bank_statement_provider_dummy.py rename to account_statement_import_online/tests/online_bank_statement_provider_dummy.py diff --git a/account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py b/account_statement_import_online/tests/test_account_bank_statement_import_online.py similarity index 100% rename from account_bank_statement_import_online/tests/test_account_bank_statement_import_online.py rename to account_statement_import_online/tests/test_account_bank_statement_import_online.py diff --git a/account_statement_import_online/views/account_journal.xml b/account_statement_import_online/views/account_journal.xml new file mode 100644 index 00000000..53c5ea70 --- /dev/null +++ b/account_statement_import_online/views/account_journal.xml @@ -0,0 +1,63 @@ + + + + + account.journal.form + account.journal + + + + + + + + + + Online Bank Statements Pull Wizard + ir.actions.server + + + code + + if records: + action = records.action_online_bank_statements_pull_wizard() + + + diff --git a/account_bank_statement_import_online/views/online_bank_statement_provider.xml b/account_statement_import_online/views/online_bank_statement_provider.xml similarity index 100% rename from account_bank_statement_import_online/views/online_bank_statement_provider.xml rename to account_statement_import_online/views/online_bank_statement_provider.xml diff --git a/account_bank_statement_import_online/wizards/__init__.py b/account_statement_import_online/wizards/__init__.py similarity index 100% rename from account_bank_statement_import_online/wizards/__init__.py rename to account_statement_import_online/wizards/__init__.py diff --git a/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py b/account_statement_import_online/wizards/online_bank_statement_pull_wizard.py similarity index 100% rename from account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.py rename to account_statement_import_online/wizards/online_bank_statement_pull_wizard.py diff --git a/account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.xml b/account_statement_import_online/wizards/online_bank_statement_pull_wizard.xml similarity index 100% rename from account_bank_statement_import_online/wizards/online_bank_statement_pull_wizard.xml rename to account_statement_import_online/wizards/online_bank_statement_pull_wizard.xml diff --git a/account_bank_statement_import_online_ponto/README.rst b/account_statement_import_online_ponto/README.rst similarity index 87% rename from account_bank_statement_import_online_ponto/README.rst rename to account_statement_import_online_ponto/README.rst index c8a4a96f..9e68fc1a 100644 --- a/account_bank_statement_import_online_ponto/README.rst +++ b/account_statement_import_online_ponto/README.rst @@ -14,13 +14,13 @@ Online Bank Statements: MyPonto.com :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fbank--statement--import-lightgray.png?logo=github - :target: https://github.com/OCA/bank-statement-import/tree/13.0/account_bank_statement_import_online_ponto + :target: https://github.com/OCA/bank-statement-import/tree/14.0/account_statement_import_online_ponto :alt: OCA/bank-statement-import .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png - :target: https://translation.odoo-community.org/projects/bank-statement-import-13-0/bank-statement-import-13-0-account_bank_statement_import_online_ponto + :target: https://translation.odoo-community.org/projects/bank-statement-import-14-0/bank-statement-import-14-0-account_statement_import_online_ponto :alt: Translate me on Weblate .. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png - :target: https://runbot.odoo-community.org/runbot/174/13.0 + :target: https://runbot.odoo-community.org/runbot/174/14.0 :alt: Try me on Runbot |badge1| |badge2| |badge3| |badge4| |badge5| @@ -83,7 +83,7 @@ Bug Tracker Bugs are tracked on `GitHub 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 `_. +`feedback `_. Do not contact contributors directly about support or help with technical issues. @@ -104,6 +104,10 @@ Contributors * Pedro M. Baeza * João Marques +* `Therp BV `__ + + * Ronald Portier + Maintainers ~~~~~~~~~~~ @@ -117,6 +121,6 @@ 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. -This module is part of the `OCA/bank-statement-import `_ project on GitHub. +This module is part of the `OCA/bank-statement-import `_ project on GitHub. You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/account_bank_statement_import_online_ponto/__init__.py b/account_statement_import_online_ponto/__init__.py similarity index 70% rename from account_bank_statement_import_online_ponto/__init__.py rename to account_statement_import_online_ponto/__init__.py index de73a3e3..31660d6a 100644 --- a/account_bank_statement_import_online_ponto/__init__.py +++ b/account_statement_import_online_ponto/__init__.py @@ -1,4 +1,3 @@ -# Copyright 2020 Florent de Labarre # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). from . import models diff --git a/account_bank_statement_import_online_ponto/__manifest__.py b/account_statement_import_online_ponto/__manifest__.py similarity index 84% rename from account_bank_statement_import_online_ponto/__manifest__.py rename to account_statement_import_online_ponto/__manifest__.py index b77980c3..b3e124a7 100644 --- a/account_bank_statement_import_online_ponto/__manifest__.py +++ b/account_statement_import_online_ponto/__manifest__.py @@ -3,12 +3,12 @@ # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). { "name": "Online Bank Statements: MyPonto.com", - "version": "13.0.1.0.0", + "version": "14.0.1.0.0", "category": "Account", "website": "https://github.com/OCA/bank-statement-import", "author": "Florent de Labarre, Odoo Community Association (OCA)", "license": "AGPL-3", "installable": True, - "depends": ["account_bank_statement_import_online"], + "depends": ["account_statement_import_online"], "data": ["view/online_bank_statement_provider.xml"], } diff --git a/account_statement_import_online_ponto/i18n/account_statement_import_online_ponto.pot b/account_statement_import_online_ponto/i18n/account_statement_import_online_ponto.pot new file mode 100644 index 00000000..42d3db9d --- /dev/null +++ b/account_statement_import_online_ponto/i18n/account_statement_import_online_ponto.pot @@ -0,0 +1,97 @@ +# Translation of Odoo Server. +# This file contains the translation of the following modules: +# * account_statement_import_online_ponto +# +msgid "" +msgstr "" +"Project-Id-Version: Odoo Server 13.0\n" +"Report-Msgid-Bugs-To: \n" +"Last-Translator: \n" +"Language-Team: \n" +"MIME-Version: 1.0\n" +"Content-Type: text/plain; charset=UTF-8\n" +"Content-Transfer-Encoding: \n" +"Plural-Forms: \n" + +#. module: account_statement_import_online_ponto +#: code:addons/account_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 +#: code:addons/account_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 +#, python-format +msgid "" +"%s \n" +"\n" +" %s" +msgstr "" + +#. module: account_statement_import_online_ponto +#: code:addons/account_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 +#, python-format +msgid "" +"Error during Create Synchronisation %s \n" +"\n" +" %s" +msgstr "" + +#. module: account_statement_import_online_ponto +#: code:addons/account_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 +#, python-format +msgid "" +"Error during get transaction.\n" +"\n" +"%s \n" +"\n" +" %s" +msgstr "" + +#. module: account_statement_import_online_ponto +#: model_terms:ir.ui.view,arch_db:account_statement_import_online_ponto.online_bank_statement_provider_form +msgid "Login" +msgstr "" + +#. module: account_statement_import_online_ponto +#: model:ir.model,name:account_statement_import_online_ponto.model_online_bank_statement_provider +msgid "Online Bank Statement Provider" +msgstr "" + +#. module: account_statement_import_online_ponto +#: code:addons/account_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 +#, python-format +msgid "Please fill login and key." +msgstr "" + +#. module: account_statement_import_online_ponto +#: code:addons/account_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 +#, python-format +msgid "Ponto : no token" +msgstr "" + +#. module: account_statement_import_online_ponto +#: code:addons/account_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py:0 +#, python-format +msgid "Ponto : wrong configuration, unknow account %s" +msgstr "" + +#. module: account_statement_import_online_ponto +#: model:ir.model.fields,field_description:account_statement_import_online_ponto.field_online_bank_statement_provider__ponto_last_identifier +msgid "Ponto Last Identifier" +msgstr "" + +#. module: account_statement_import_online_ponto +#: model:ir.model.fields,field_description:account_statement_import_online_ponto.field_online_bank_statement_provider__ponto_token +msgid "Ponto Token" +msgstr "" + +#. module: account_statement_import_online_ponto +#: model:ir.model.fields,field_description:account_statement_import_online_ponto.field_online_bank_statement_provider__ponto_token_expiration +msgid "Ponto Token Expiration" +msgstr "" + +#. module: account_statement_import_online_ponto +#: model_terms:ir.ui.view,arch_db:account_statement_import_online_ponto.online_bank_statement_provider_form +msgid "Reset Last identifier." +msgstr "" + +#. module: account_statement_import_online_ponto +#: model_terms:ir.ui.view,arch_db:account_statement_import_online_ponto.online_bank_statement_provider_form +msgid "Secret Key" +msgstr "" diff --git a/account_bank_statement_import_online_ponto/models/__init__.py b/account_statement_import_online_ponto/models/__init__.py similarity index 76% rename from account_bank_statement_import_online_ponto/models/__init__.py rename to account_statement_import_online_ponto/models/__init__.py index cc57537b..236b6f14 100644 --- a/account_bank_statement_import_online_ponto/models/__init__.py +++ b/account_statement_import_online_ponto/models/__init__.py @@ -1,4 +1,3 @@ -# Copyright 2020 Florent de Labarre # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). from . import online_bank_statement_provider_ponto diff --git a/account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py b/account_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py similarity index 100% rename from account_bank_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py rename to account_statement_import_online_ponto/models/online_bank_statement_provider_ponto.py diff --git a/account_bank_statement_import_online_ponto/readme/CONFIGURE.rst b/account_statement_import_online_ponto/readme/CONFIGURE.rst similarity index 100% rename from account_bank_statement_import_online_ponto/readme/CONFIGURE.rst rename to account_statement_import_online_ponto/readme/CONFIGURE.rst diff --git a/account_bank_statement_import_online_ponto/readme/CONTRIBUTORS.rst b/account_statement_import_online_ponto/readme/CONTRIBUTORS.rst similarity index 58% rename from account_bank_statement_import_online_ponto/readme/CONTRIBUTORS.rst rename to account_statement_import_online_ponto/readme/CONTRIBUTORS.rst index e9b8f87d..2eddc1b5 100644 --- a/account_bank_statement_import_online_ponto/readme/CONTRIBUTORS.rst +++ b/account_statement_import_online_ponto/readme/CONTRIBUTORS.rst @@ -3,3 +3,7 @@ * Pedro M. Baeza * João Marques + +* `Therp BV `__ + + * Ronald Portier diff --git a/account_bank_statement_import_online_ponto/readme/DESCRIPTION.rst b/account_statement_import_online_ponto/readme/DESCRIPTION.rst similarity index 100% rename from account_bank_statement_import_online_ponto/readme/DESCRIPTION.rst rename to account_statement_import_online_ponto/readme/DESCRIPTION.rst diff --git a/account_bank_statement_import_online_ponto/readme/USAGE.rst b/account_statement_import_online_ponto/readme/USAGE.rst similarity index 100% rename from account_bank_statement_import_online_ponto/readme/USAGE.rst rename to account_statement_import_online_ponto/readme/USAGE.rst diff --git a/account_bank_statement_import_online_ponto/static/description/icon.png b/account_statement_import_online_ponto/static/description/icon.png similarity index 100% rename from account_bank_statement_import_online_ponto/static/description/icon.png rename to account_statement_import_online_ponto/static/description/icon.png diff --git a/account_bank_statement_import_online_ponto/static/description/index.html b/account_statement_import_online_ponto/static/description/index.html similarity index 90% rename from account_bank_statement_import_online_ponto/static/description/index.html rename to account_statement_import_online_ponto/static/description/index.html index f550b620..7f55543e 100644 --- a/account_bank_statement_import_online_ponto/static/description/index.html +++ b/account_statement_import_online_ponto/static/description/index.html @@ -367,7 +367,7 @@ ul.auto-toc { !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! --> -

    Beta License: AGPL-3 OCA/bank-statement-import Translate me on Weblate Try me on Runbot

    +

    Beta License: AGPL-3 OCA/bank-statement-import Translate me on Weblate Try me on Runbot

    This module provides online bank statements from MyPonto.com.

    Table of contents

    @@ -431,7 +431,7 @@ transactions.

    Bugs are tracked on GitHub 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.

    +feedback.

    Do not contact contributors directly about support or help with technical issues.

    @@ -451,6 +451,10 @@ If you spotted it first, help us smashing it by providing a detailed and welcome
  • João Marques
  • +
  • Therp BV +
  • @@ -460,7 +464,7 @@ If you spotted it first, help us smashing it by providing a detailed and welcome

    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.

    -

    This module is part of the OCA/bank-statement-import project on GitHub.

    +

    This module is part of the OCA/bank-statement-import project on GitHub.

    You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

    diff --git a/account_bank_statement_import_online_ponto/tests/__init__.py b/account_statement_import_online_ponto/tests/__init__.py similarity index 51% rename from account_bank_statement_import_online_ponto/tests/__init__.py rename to account_statement_import_online_ponto/tests/__init__.py index 8e1252ec..d1f2895e 100644 --- a/account_bank_statement_import_online_ponto/tests/__init__.py +++ b/account_statement_import_online_ponto/tests/__init__.py @@ -1,3 +1,3 @@ # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). -from . import test_account_bank_statement_import_online_ponto +from . import test_account_statement_import_online_ponto diff --git a/account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py b/account_statement_import_online_ponto/tests/test_account_statement_import_online_ponto.py similarity index 98% rename from account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py rename to account_statement_import_online_ponto/tests/test_account_statement_import_online_ponto.py index 8f355c00..0d99a07d 100644 --- a/account_bank_statement_import_online_ponto/tests/test_account_bank_statement_import_online_ponto.py +++ b/account_statement_import_online_ponto/tests/test_account_statement_import_online_ponto.py @@ -7,7 +7,7 @@ from unittest import mock from odoo import fields from odoo.tests import common -_module_ns = "odoo.addons.account_bank_statement_import_online_ponto" +_module_ns = "odoo.addons.account_statement_import_online_ponto" _provider_class = ( _module_ns + ".models.online_bank_statement_provider_ponto" diff --git a/account_bank_statement_import_online_ponto/view/online_bank_statement_provider.xml b/account_statement_import_online_ponto/view/online_bank_statement_provider.xml similarity index 92% rename from account_bank_statement_import_online_ponto/view/online_bank_statement_provider.xml rename to account_statement_import_online_ponto/view/online_bank_statement_provider.xml index d487be5c..3a8025b0 100644 --- a/account_bank_statement_import_online_ponto/view/online_bank_statement_provider.xml +++ b/account_statement_import_online_ponto/view/online_bank_statement_provider.xml @@ -5,7 +5,7 @@ online.bank.statement.provider diff --git a/setup/account_bank_statement_import_online/odoo/addons/account_bank_statement_import_online b/setup/account_bank_statement_import_online/odoo/addons/account_bank_statement_import_online deleted file mode 120000 index b31ca33c..00000000 --- a/setup/account_bank_statement_import_online/odoo/addons/account_bank_statement_import_online +++ /dev/null @@ -1 +0,0 @@ -../../../../account_bank_statement_import_online \ No newline at end of file diff --git a/setup/account_bank_statement_import_online_ponto/odoo/addons/account_bank_statement_import_online_ponto b/setup/account_bank_statement_import_online_ponto/odoo/addons/account_bank_statement_import_online_ponto deleted file mode 120000 index e413ef48..00000000 --- a/setup/account_bank_statement_import_online_ponto/odoo/addons/account_bank_statement_import_online_ponto +++ /dev/null @@ -1 +0,0 @@ -../../../../account_bank_statement_import_online_ponto \ No newline at end of file diff --git a/setup/account_statement_import_online/odoo/addons/account_statement_import_online b/setup/account_statement_import_online/odoo/addons/account_statement_import_online new file mode 120000 index 00000000..50284bd6 --- /dev/null +++ b/setup/account_statement_import_online/odoo/addons/account_statement_import_online @@ -0,0 +1 @@ +../../../../account_statement_import_online \ No newline at end of file diff --git a/setup/account_bank_statement_import_online/setup.py b/setup/account_statement_import_online/setup.py similarity index 100% rename from setup/account_bank_statement_import_online/setup.py rename to setup/account_statement_import_online/setup.py diff --git a/setup/account_statement_import_online_ponto/odoo/addons/account_statement_import_online_ponto b/setup/account_statement_import_online_ponto/odoo/addons/account_statement_import_online_ponto new file mode 120000 index 00000000..efde64a7 --- /dev/null +++ b/setup/account_statement_import_online_ponto/odoo/addons/account_statement_import_online_ponto @@ -0,0 +1 @@ +../../../../account_statement_import_online_ponto \ No newline at end of file diff --git a/setup/account_bank_statement_import_online_ponto/setup.py b/setup/account_statement_import_online_ponto/setup.py similarity index 100% rename from setup/account_bank_statement_import_online_ponto/setup.py rename to setup/account_statement_import_online_ponto/setup.py From 0578dadc9cfb4ec9a35032906ec2e7e2ee4ef177 Mon Sep 17 00:00:00 2001 From: Alexis de Lattre Date: Wed, 16 Jun 2021 23:40:52 +0200 Subject: [PATCH 31/32] account_statement_import_online: usability improvement on form view of online.bank.statement.provider: avoid speading the information on 3 tabs. As there are just a few fields, let's keep all the information directly visible. Fix warning on search view of online.bank.statement.provider Fix some tests Button on journal form view to access the wizard The wizard now returns the bank statements of the journal(s) Fix wired strings --- .../__manifest__.py | 2 +- .../models/account_journal.py | 14 --- .../online_bank_statement_provider.xml | 1 - .../online_bank_statement_provider_dummy.py | 2 +- ...st_account_bank_statement_import_online.py | 7 +- .../views/account_journal.xml | 27 ++++-- .../views/online_bank_statement_provider.xml | 94 +++++++++---------- .../online_bank_statement_pull_wizard.py | 33 ++++++- .../online_bank_statement_pull_wizard.xml | 26 ++--- 9 files changed, 112 insertions(+), 94 deletions(-) diff --git a/account_statement_import_online/__manifest__.py b/account_statement_import_online/__manifest__.py index 1fcfa9ee..329629fb 100644 --- a/account_statement_import_online/__manifest__.py +++ b/account_statement_import_online/__manifest__.py @@ -20,9 +20,9 @@ "data/account_statement_import_online.xml", "security/ir.model.access.csv", "security/online_bank_statement_provider.xml", + "wizards/online_bank_statement_pull_wizard.xml", "views/account_journal.xml", "views/online_bank_statement_provider.xml", - "wizards/online_bank_statement_pull_wizard.xml", ], "installable": True, } diff --git a/account_statement_import_online/models/account_journal.py b/account_statement_import_online/models/account_journal.py index 53764c25..df89ee1b 100644 --- a/account_statement_import_online/models/account_journal.py +++ b/account_statement_import_online/models/account_journal.py @@ -76,17 +76,3 @@ class AccountJournal(models.Model): if "bank_statements_source" in vals or "online_bank_statement_provider" in vals: self._update_online_bank_statement_provider_id() return res - - def action_online_bank_statements_pull_wizard(self): - provider_ids = self.mapped("online_bank_statement_provider_id").ids - return { - "name": _("Online Bank Statement Pull Wizard"), - "type": "ir.actions.act_window", - "res_model": "online.bank.statement.pull.wizard", - "views": [[False, "form"]], - "target": "new", - "context": { - "default_provider_ids": [(6, False, provider_ids)], - "active_test": False, - }, - } diff --git a/account_statement_import_online/security/online_bank_statement_provider.xml b/account_statement_import_online/security/online_bank_statement_provider.xml index 0b1ae8e0..db8c82d0 100644 --- a/account_statement_import_online/security/online_bank_statement_provider.xml +++ b/account_statement_import_online/security/online_bank_statement_provider.xml @@ -8,7 +8,6 @@ Online Bank Statement Provider multi-company - ['|',('company_id','=',False),('company_id','in',company_ids)] diff --git a/account_statement_import_online/tests/online_bank_statement_provider_dummy.py b/account_statement_import_online/tests/online_bank_statement_provider_dummy.py index f2e7b5fb..e7b88458 100644 --- a/account_statement_import_online/tests/online_bank_statement_provider_dummy.py +++ b/account_statement_import_online/tests/online_bank_statement_provider_dummy.py @@ -56,7 +56,7 @@ class OnlineBankStatementProviderDummy(models.Model): transaction_date = fields.Datetime.to_string(transaction_date) lines.append( { - "name": "payment", + "payment_ref": "payment", "amount": amount, "date": transaction_date, "unique_import_id": str( diff --git a/account_statement_import_online/tests/test_account_bank_statement_import_online.py b/account_statement_import_online/tests/test_account_bank_statement_import_online.py index 335b5f70..e16ce1f3 100644 --- a/account_statement_import_online/tests/test_account_bank_statement_import_online.py +++ b/account_statement_import_online/tests/test_account_bank_statement_import_online.py @@ -383,10 +383,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): order="date asc", ) self.assertFalse(statements[0].balance_start) - self.assertFalse(statements[0].balance_end_real) self.assertTrue(statements[0].balance_end) self.assertTrue(statements[1].balance_start) - self.assertFalse(statements[1].balance_end_real) def test_wizard(self): journal = self.AccountJournal.create( @@ -398,11 +396,8 @@ class TestAccountBankAccountStatementImportOnline(common.TransactionCase): "online_bank_statement_provider": "dummy", } ) - action = journal.action_online_bank_statements_pull_wizard() - self.assertTrue(action["context"]["default_provider_ids"][0][2]) - wizard = self.OnlineBankStatementPullWizard.with_context( - action["context"] + active_model="account.journal", active_id=journal.id ).create( {"date_since": self.now - relativedelta(hours=1), "date_until": self.now} ) diff --git a/account_statement_import_online/views/account_journal.xml b/account_statement_import_online/views/account_journal.xml index 53c5ea70..fe319292 100644 --- a/account_statement_import_online/views/account_journal.xml +++ b/account_statement_import_online/views/account_journal.xml @@ -47,17 +47,28 @@ />
    + +
    +
    +
    - + Online Bank Statements Pull Wizard - ir.actions.server - + online.bank.statement.pull.wizard + new + form - code - - if records: - action = records.action_online_bank_statements_pull_wizard() - + list + diff --git a/account_statement_import_online/views/online_bank_statement_provider.xml b/account_statement_import_online/views/online_bank_statement_provider.xml index 56d24dfb..de3f26aa 100644 --- a/account_statement_import_online/views/online_bank_statement_provider.xml +++ b/account_statement_import_online/views/online_bank_statement_provider.xml @@ -10,11 +10,19 @@ online.bank.statement.provider + + + + @@ -38,63 +46,41 @@
    -
    - -
    - - - - - - - - - - - - - - - - - - - + + + +