From d0f4e1b67ca1081cf63b4d2fcff889b65e476053 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?V=C3=ADctor=20Mart=C3=ADnez?= Date: Mon, 14 Nov 2022 08:29:43 +0100 Subject: [PATCH] [MIG] account_payment_order_notification: Migration to 14.0 TT40457 --- account_payment_order_notification/README.rst | 20 +++++++++---------- .../__manifest__.py | 2 +- .../data/mail_template_data.xml | 1 - .../account_payment_order_notification.pot | 5 ++++- account_payment_order_notification/i18n/es.po | 3 +++ .../models/account_payment_order.py | 2 +- .../readme/CONFIGURE.rst | 6 +++--- .../readme/USAGE.rst | 4 ++-- .../security/ir.model.access.csv | 2 ++ .../static/description/index.html | 16 +++++++-------- ...test_account_payment_order_notification.py | 4 ++-- 11 files changed, 36 insertions(+), 29 deletions(-) diff --git a/account_payment_order_notification/README.rst b/account_payment_order_notification/README.rst index 66e20bae0..b4375853d 100644 --- a/account_payment_order_notification/README.rst +++ b/account_payment_order_notification/README.rst @@ -14,13 +14,13 @@ Account Payment Order Notification :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--payment-lightgray.png?logo=github - :target: https://github.com/OCA/bank-payment/tree/13.0/account_payment_order_notification + :target: https://github.com/OCA/bank-payment/tree/14.0/account_payment_order_notification :alt: OCA/bank-payment .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png - :target: https://translation.odoo-community.org/projects/bank-payment-13-0/bank-payment-13-0-account_payment_order_notification + :target: https://translation.odoo-community.org/projects/bank-payment-14-0/bank-payment-14-0-account_payment_order_notification :alt: Translate me on Weblate .. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png - :target: https://runbot.odoo-community.org/runbot/173/13.0 + :target: https://runbot.odoo-community.org/runbot/173/14.0 :alt: Try me on Runbot |badge1| |badge2| |badge3| |badge4| |badge5| @@ -37,22 +37,22 @@ Configuration To configure this module, you need to: -#. Go to *Invoicing > Configuration > Payment Modes* and create a payment mode if you wish. +#. Go to *Invoicing > Configuration > Payment Modes* and create a payment mode, if you wish. -#. Go to *Invoicing > Customers > Customers* and creates a new record as follows: +#. Go to *Invoicing > Customers > Customers* and create a new record as follows: * Name: Test customer 1 * Email: customer1@test.com -#. Go to *Invoicing > Customers > Customers* and creates a new record as follows: +#. Go to *Invoicing > Customers > Customers* and create a new record as follows: * Name: Test customer 2 * Email: (empty) Usage ===== -#. Go to *Invoicing > Customers > Invoices* and creates one or more invoices linked to the payment mode. +#. Go to *Invoicing > Customers > Invoices* and create one or more invoices linked to the payment mode. #. Go to *Invoicing > Customers > Invoices* select the invoices created and execute the action called "Post entries". -#. Go to *Invoicing > Customers > Invoices* select the invoices created and execute the action called "Add to Payment/Debit Order" and creates a payment order. +#. Go to *Invoicing > Customers > Invoices* select the invoices created and execute the action called "Add to Payment/Debit Order" and create a payment order. #. Click on "Confirm Payments" button. #. Click on "Generate Payment File" button. #. Click on "File Successfully Uploaded" button. @@ -68,7 +68,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. @@ -109,6 +109,6 @@ Current `maintainer `__: |maintainer-victoralmau| -This module is part of the `OCA/bank-payment `_ project on GitHub. +This module is part of the `OCA/bank-payment `_ project on GitHub. You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/account_payment_order_notification/__manifest__.py b/account_payment_order_notification/__manifest__.py index 23dd90c56..7cef92c1a 100644 --- a/account_payment_order_notification/__manifest__.py +++ b/account_payment_order_notification/__manifest__.py @@ -2,7 +2,7 @@ # License AGPL-3.0 or later (https://www.gnu.org/licenses/agpl). { "name": "Account Payment Order Notification", - "version": "13.0.1.0.1", + "version": "14.0.1.0.0", "category": "Banking addons", "website": "https://github.com/OCA/bank-payment", "author": "Tecnativa, Odoo Community Association (OCA)", diff --git a/account_payment_order_notification/data/mail_template_data.xml b/account_payment_order_notification/data/mail_template_data.xml index 07c03a997..5b127b1d1 100644 --- a/account_payment_order_notification/data/mail_template_data.xml +++ b/account_payment_order_notification/data/mail_template_data.xml @@ -42,7 +42,6 @@ ]]> ${object.partner_id.lang} - diff --git a/account_payment_order_notification/i18n/account_payment_order_notification.pot b/account_payment_order_notification/i18n/account_payment_order_notification.pot index 5d5e52d10..d2ae9a89c 100644 --- a/account_payment_order_notification/i18n/account_payment_order_notification.pot +++ b/account_payment_order_notification/i18n/account_payment_order_notification.pot @@ -4,7 +4,7 @@ # msgid "" msgstr "" -"Project-Id-Version: Odoo Server 13.0\n" +"Project-Id-Version: Odoo Server 14.0\n" "Report-Msgid-Bugs-To: \n" "Last-Translator: \n" "Language-Team: \n" @@ -93,6 +93,7 @@ msgid "Created on" msgstr "" #. module: account_payment_order_notification +#: model:ir.model.fields,field_description:account_payment_order_notification.field_account_payment_order__display_name #: model:ir.model.fields,field_description:account_payment_order_notification.field_account_payment_order_notification__display_name #: model:ir.model.fields,field_description:account_payment_order_notification.field_wizard_account_payment_order_notification__display_name #: model:ir.model.fields,field_description:account_payment_order_notification.field_wizard_account_payment_order_notification_line__display_name @@ -131,6 +132,7 @@ msgid "Group By" msgstr "" #. module: account_payment_order_notification +#: model:ir.model.fields,field_description:account_payment_order_notification.field_account_payment_order__id #: model:ir.model.fields,field_description:account_payment_order_notification.field_account_payment_order_notification__id #: model:ir.model.fields,field_description:account_payment_order_notification.field_wizard_account_payment_order_notification__id #: model:ir.model.fields,field_description:account_payment_order_notification.field_wizard_account_payment_order_notification_line__id @@ -155,6 +157,7 @@ msgid "Is Follower" msgstr "" #. module: account_payment_order_notification +#: model:ir.model.fields,field_description:account_payment_order_notification.field_account_payment_order____last_update #: model:ir.model.fields,field_description:account_payment_order_notification.field_account_payment_order_notification____last_update #: model:ir.model.fields,field_description:account_payment_order_notification.field_wizard_account_payment_order_notification____last_update #: model:ir.model.fields,field_description:account_payment_order_notification.field_wizard_account_payment_order_notification_line____last_update diff --git a/account_payment_order_notification/i18n/es.po b/account_payment_order_notification/i18n/es.po index 62f236fa6..6fc741753 100644 --- a/account_payment_order_notification/i18n/es.po +++ b/account_payment_order_notification/i18n/es.po @@ -136,6 +136,7 @@ msgid "Created on" msgstr "Creado el" #. module: account_payment_order_notification +#: model:ir.model.fields,field_description:account_payment_order_notification.field_account_payment_order__display_name #: model:ir.model.fields,field_description:account_payment_order_notification.field_account_payment_order_notification__display_name #: model:ir.model.fields,field_description:account_payment_order_notification.field_wizard_account_payment_order_notification__display_name #: model:ir.model.fields,field_description:account_payment_order_notification.field_wizard_account_payment_order_notification_line__display_name @@ -174,6 +175,7 @@ msgid "Group By" msgstr "Agrupar por" #. module: account_payment_order_notification +#: model:ir.model.fields,field_description:account_payment_order_notification.field_account_payment_order__id #: model:ir.model.fields,field_description:account_payment_order_notification.field_account_payment_order_notification__id #: model:ir.model.fields,field_description:account_payment_order_notification.field_wizard_account_payment_order_notification__id #: model:ir.model.fields,field_description:account_payment_order_notification.field_wizard_account_payment_order_notification_line__id @@ -198,6 +200,7 @@ msgid "Is Follower" msgstr "Es seguidor" #. module: account_payment_order_notification +#: model:ir.model.fields,field_description:account_payment_order_notification.field_account_payment_order____last_update #: model:ir.model.fields,field_description:account_payment_order_notification.field_account_payment_order_notification____last_update #: model:ir.model.fields,field_description:account_payment_order_notification.field_wizard_account_payment_order_notification____last_update #: model:ir.model.fields,field_description:account_payment_order_notification.field_wizard_account_payment_order_notification_line____last_update diff --git a/account_payment_order_notification/models/account_payment_order.py b/account_payment_order_notification/models/account_payment_order.py index 12098a582..912a90080 100644 --- a/account_payment_order_notification/models/account_payment_order.py +++ b/account_payment_order_notification/models/account_payment_order.py @@ -30,7 +30,7 @@ class AccountPaymentOrder(models.Model): "account_payment_order_notification", "account_payment_order_notification_action", ) - action = self.env.ref(xml_id).read()[0] + action = self.env["ir.actions.act_window"]._for_xml_id(xml_id) action["domain"] = [("order_id", "=", self.id)] return action diff --git a/account_payment_order_notification/readme/CONFIGURE.rst b/account_payment_order_notification/readme/CONFIGURE.rst index b754ede03..eca598c8e 100644 --- a/account_payment_order_notification/readme/CONFIGURE.rst +++ b/account_payment_order_notification/readme/CONFIGURE.rst @@ -1,11 +1,11 @@ To configure this module, you need to: -#. Go to *Invoicing > Configuration > Payment Modes* and create a payment mode if you wish. +#. Go to *Invoicing > Configuration > Payment Modes* and create a payment mode, if you wish. -#. Go to *Invoicing > Customers > Customers* and creates a new record as follows: +#. Go to *Invoicing > Customers > Customers* and create a new record as follows: * Name: Test customer 1 * Email: customer1@test.com -#. Go to *Invoicing > Customers > Customers* and creates a new record as follows: +#. Go to *Invoicing > Customers > Customers* and create a new record as follows: * Name: Test customer 2 * Email: (empty) diff --git a/account_payment_order_notification/readme/USAGE.rst b/account_payment_order_notification/readme/USAGE.rst index 011ff6653..433a8a2ff 100644 --- a/account_payment_order_notification/readme/USAGE.rst +++ b/account_payment_order_notification/readme/USAGE.rst @@ -1,6 +1,6 @@ -#. Go to *Invoicing > Customers > Invoices* and creates one or more invoices linked to the payment mode. +#. Go to *Invoicing > Customers > Invoices* and create one or more invoices linked to the payment mode. #. Go to *Invoicing > Customers > Invoices* select the invoices created and execute the action called "Post entries". -#. Go to *Invoicing > Customers > Invoices* select the invoices created and execute the action called "Add to Payment/Debit Order" and creates a payment order. +#. Go to *Invoicing > Customers > Invoices* select the invoices created and execute the action called "Add to Payment/Debit Order" and create a payment order. #. Click on "Confirm Payments" button. #. Click on "Generate Payment File" button. #. Click on "File Successfully Uploaded" button. diff --git a/account_payment_order_notification/security/ir.model.access.csv b/account_payment_order_notification/security/ir.model.access.csv index 2e294ba7d..01d3fe312 100644 --- a/account_payment_order_notification/security/ir.model.access.csv +++ b/account_payment_order_notification/security/ir.model.access.csv @@ -1,2 +1,4 @@ id,name,model_id:id,group_id:id,perm_read,perm_write,perm_create,perm_unlink access_account_payment_order_notification,account.payment.order.notification.manager,model_account_payment_order_notification,account_payment_order.group_account_payment,1,1,1,1 +access_wizard_account_payment_order_notification,access_wizard_account_payment_order_notification,model_wizard_account_payment_order_notification,account_payment_order.group_account_payment,1,1,1,1 +access_wizard_account_payment_order_notification_line,access_wizard_account_payment_order_notification_line,model_wizard_account_payment_order_notification_line,account_payment_order.group_account_payment,1,1,1,1 diff --git a/account_payment_order_notification/static/description/index.html b/account_payment_order_notification/static/description/index.html index 91b6788a2..ac9be143d 100644 --- a/account_payment_order_notification/static/description/index.html +++ b/account_payment_order_notification/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-payment Translate me on Weblate Try me on Runbot

+

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

This module adds a button on debit / payment orders to send an email to each related partner with the details of their transactions.

Table of contents

@@ -387,9 +387,9 @@ ul.auto-toc {

Configuration

To configure this module, you need to:

    -
  1. Go to Invoicing > Configuration > Payment Modes and create a payment mode if you wish.
  2. +
  3. Go to Invoicing > Configuration > Payment Modes and create a payment mode, if you wish.
  4. -
    Go to Invoicing > Customers > Customers and creates a new record as follows:
    +
    Go to Invoicing > Customers > Customers and create a new record as follows:
  5. -
    Go to Invoicing > Customers > Customers and creates a new record as follows:
    +
    Go to Invoicing > Customers > Customers and create a new record as follows:
    • Name: Test customer 2
    • Email: (empty)
    • @@ -411,9 +411,9 @@ ul.auto-toc {

      Usage

        -
      1. Go to Invoicing > Customers > Invoices and creates one or more invoices linked to the payment mode.
      2. +
      3. Go to Invoicing > Customers > Invoices and create one or more invoices linked to the payment mode.
      4. Go to Invoicing > Customers > Invoices select the invoices created and execute the action called “Post entries”.
      5. -
      6. Go to Invoicing > Customers > Invoices select the invoices created and execute the action called “Add to Payment/Debit Order” and creates a payment order.
      7. +
      8. Go to Invoicing > Customers > Invoices select the invoices created and execute the action called “Add to Payment/Debit Order” and create a payment order.
      9. Click on “Confirm Payments” button.
      10. Click on “Generate Payment File” button.
      11. Click on “File Successfully Uploaded” button.
      12. @@ -429,7 +429,7 @@ ul.auto-toc {

        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.

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

      Current maintainer:

      victoralmau

      -

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

      +

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

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

diff --git a/account_payment_order_notification/tests/test_account_payment_order_notification.py b/account_payment_order_notification/tests/test_account_payment_order_notification.py index 2f53cc06b..3edf787c3 100644 --- a/account_payment_order_notification/tests/test_account_payment_order_notification.py +++ b/account_payment_order_notification/tests/test_account_payment_order_notification.py @@ -20,9 +20,9 @@ class TestAccountPaymentOrderNotification(common.SavepointCase): ) cls.mt_comment = cls.env.ref("mail.mt_comment") - def _create_invoice(self, partner, invoice_type="out_invoice"): + def _create_invoice(self, partner, move_type="out_invoice"): invoice_form = Form( - self.env["account.move"].with_context(default_type=invoice_type) + self.env["account.move"].with_context(default_move_type=move_type) ) invoice_form.partner_id = partner invoice_form.payment_mode_id = self.payment_mode