From 637ad7e8299dcefe3a9e8d2364bef587197bf74e Mon Sep 17 00:00:00 2001 From: Murtaza Mithaiwala Date: Mon, 19 Dec 2022 13:46:02 +0530 Subject: [PATCH] [16.0][MIG] account_banking_ach_direct_debit --- account_banking_ach_direct_debit/README.rst | 10 +++++----- account_banking_ach_direct_debit/__init__.py | 1 - account_banking_ach_direct_debit/__manifest__.py | 1 - account_banking_ach_direct_debit/post_install.py | 16 ---------------- .../static/description/index.html | 8 ++++---- 5 files changed, 9 insertions(+), 27 deletions(-) delete mode 100644 account_banking_ach_direct_debit/post_install.py diff --git a/account_banking_ach_direct_debit/README.rst b/account_banking_ach_direct_debit/README.rst index e8f71af6..d5028902 100644 --- a/account_banking_ach_direct_debit/README.rst +++ b/account_banking_ach_direct_debit/README.rst @@ -14,13 +14,13 @@ Account Banking ACH Direct Debit :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Fl10n--usa-lightgray.png?logo=github - :target: https://github.com/OCA/l10n-usa/tree/14.0/account_banking_ach_direct_debit + :target: https://github.com/OCA/l10n-usa/tree/16.0/account_banking_ach_direct_debit :alt: OCA/l10n-usa .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png - :target: https://translation.odoo-community.org/projects/l10n-usa-14-0/l10n-usa-14-0-account_banking_ach_direct_debit + :target: https://translation.odoo-community.org/projects/l10n-usa-16-0/l10n-usa-16-0-account_banking_ach_direct_debit :alt: Translate me on Weblate .. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png - :target: https://runbot.odoo-community.org/runbot/203/14.0 + :target: https://runbot.odoo-community.org/runbot/203/16.0 :alt: Try me on Runbot |badge1| |badge2| |badge3| |badge4| |badge5| @@ -69,7 +69,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. @@ -102,6 +102,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/l10n-usa `_ project on GitHub. +This module is part of the `OCA/l10n-usa `_ project on GitHub. You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/account_banking_ach_direct_debit/__init__.py b/account_banking_ach_direct_debit/__init__.py index f1a6eca6..83e553ac 100644 --- a/account_banking_ach_direct_debit/__init__.py +++ b/account_banking_ach_direct_debit/__init__.py @@ -1,4 +1,3 @@ # License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). from . import models -from .post_install import update_bank_journals diff --git a/account_banking_ach_direct_debit/__manifest__.py b/account_banking_ach_direct_debit/__manifest__.py index f6c04cf0..057b1f9b 100644 --- a/account_banking_ach_direct_debit/__manifest__.py +++ b/account_banking_ach_direct_debit/__manifest__.py @@ -19,6 +19,5 @@ "views/account_banking_mandate_view.xml", ], "demo": ["demo/ach_direct_debit_demo.xml"], - "post_init_hook": "update_bank_journals", "installable": True, } diff --git a/account_banking_ach_direct_debit/post_install.py b/account_banking_ach_direct_debit/post_install.py deleted file mode 100644 index 6a12e5a1..00000000 --- a/account_banking_ach_direct_debit/post_install.py +++ /dev/null @@ -1,16 +0,0 @@ -# License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html). - -from odoo import SUPERUSER_ID, api - - -def update_bank_journals(cr, registry): - with api.Environment.manage(): - env = api.Environment(cr, SUPERUSER_ID, {}) - journals = env["account.journal"].search([("type", "=", "bank")]) - ach_dd = env.ref( - "account_banking_ach_direct_debit.ach_direct_debit", - raise_if_not_found=False, - ) - if ach_dd: - journals.write({"inbound_payment_method_ids": [(4, ach_dd.id)]}) - return diff --git a/account_banking_ach_direct_debit/static/description/index.html b/account_banking_ach_direct_debit/static/description/index.html index 22c3e63a..4ae2f7ac 100644 --- a/account_banking_ach_direct_debit/static/description/index.html +++ b/account_banking_ach_direct_debit/static/description/index.html @@ -3,7 +3,7 @@ - + Account Banking ACH Direct Debit