diff --git a/account_invoice_qr_code_sepa_payconiq/README.rst b/account_invoice_qr_code_sepa_payconiq/README.rst index accf01e043b..449d0c01474 100644 --- a/account_invoice_qr_code_sepa_payconiq/README.rst +++ b/account_invoice_qr_code_sepa_payconiq/README.rst @@ -2,10 +2,13 @@ Account Invoice Qr Code Sepa Payconiq ===================================== -.. !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! +.. + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! !! This file is generated by oca-gen-addon-readme !! !! changes will be overwritten. !! !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! + !! source digest: sha256:0211e221ca8675a6785589d60584e334602617ea0c90110a42c4812af441b20e + !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! .. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png :target: https://odoo-community.org/page/development-status @@ -14,16 +17,16 @@ Account Invoice Qr Code Sepa Payconiq :target: http://www.gnu.org/licenses/agpl-3.0-standalone.html :alt: License: AGPL-3 .. |badge3| image:: https://img.shields.io/badge/github-OCA%2Faccount--invoicing-lightgray.png?logo=github - :target: https://github.com/OCA/account-invoicing/tree/14.0/account_invoice_qr_code_sepa_payconiq + :target: https://github.com/OCA/account-invoicing/tree/16.0/account_invoice_qr_code_sepa_payconiq :alt: OCA/account-invoicing .. |badge4| image:: https://img.shields.io/badge/weblate-Translate%20me-F47D42.png - :target: https://translation.odoo-community.org/projects/account-invoicing-14-0/account-invoicing-14-0-account_invoice_qr_code_sepa_payconiq + :target: https://translation.odoo-community.org/projects/account-invoicing-16-0/account-invoicing-16-0-account_invoice_qr_code_sepa_payconiq :alt: Translate me on Weblate -.. |badge5| image:: https://img.shields.io/badge/runbot-Try%20me-875A7B.png - :target: https://runbot.odoo-community.org/runbot/95/14.0 - :alt: Try me on Runbot +.. |badge5| image:: https://img.shields.io/badge/runboat-Try%20me-875A7B.png + :target: https://runboat.odoo-community.org/builds?repo=OCA/account-invoicing&target_branch=16.0 + :alt: Try me on Runboat -|badge1| |badge2| |badge3| |badge4| |badge5| +|badge1| |badge2| |badge3| |badge4| |badge5| This module allows to generate a QR code to be displayed on invoices. @@ -59,8 +62,8 @@ 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 `_. +If you spotted it first, help us to smash it by providing a detailed and welcomed +`feedback `_. Do not contact contributors directly about support or help with technical issues. @@ -90,6 +93,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/account-invoicing `_ project on GitHub. +This module is part of the `OCA/account-invoicing `_ project on GitHub. You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute. diff --git a/account_invoice_qr_code_sepa_payconiq/__manifest__.py b/account_invoice_qr_code_sepa_payconiq/__manifest__.py index 5ae595f6bc0..9b85daae903 100644 --- a/account_invoice_qr_code_sepa_payconiq/__manifest__.py +++ b/account_invoice_qr_code_sepa_payconiq/__manifest__.py @@ -5,7 +5,7 @@ "name": "Account Invoice Qr Code Sepa Payconiq", "summary": """ Allows to generate a qr code for Payconiq provider containing the url""", - "version": "14.0.1.0.0", + "version": "16.0.1.0.0", "license": "AGPL-3", "author": "ACSONE SA/NV,Odoo Community Association (OCA)", "website": "https://github.com/OCA/account-invoicing", diff --git a/account_invoice_qr_code_sepa_payconiq/models/res_partner_bank.py b/account_invoice_qr_code_sepa_payconiq/models/res_partner_bank.py index 3b1950babbd..747c61ca985 100644 --- a/account_invoice_qr_code_sepa_payconiq/models/res_partner_bank.py +++ b/account_invoice_qr_code_sepa_payconiq/models/res_partner_bank.py @@ -92,14 +92,18 @@ def _get_qr_code_url( structured_communication, ) - def _eligible_for_qr_code(self, qr_method, debtor_partner, currency): + def _eligible_for_qr_code( + self, qr_method, debtor_partner, currency, raises_error=True + ): if qr_method == "payconiq_qr": return ( currency.name == "EUR" and self.acc_type == "iban" and self.sanitized_acc_number[:2] in ["LU"] ) - return super()._eligible_for_qr_code(qr_method, debtor_partner, currency) + return super()._eligible_for_qr_code( + qr_method, debtor_partner, currency, raises_error=raises_error + ) def _get_qr_code_base64( self, @@ -134,7 +138,9 @@ def _get_qr_code_base64( "s": "S", "c": c_url + urllib.parse.urlencode(params), } - response = requests.get(PAYCONIQ_QR_URL, params=new_params, stream=True) + response = requests.get( + PAYCONIQ_QR_URL, params=new_params, stream=True, timeout=60 + ) raw_image = response.raw img = Image.open(raw_image) diff --git a/account_invoice_qr_code_sepa_payconiq/static/description/index.html b/account_invoice_qr_code_sepa_payconiq/static/description/index.html index 167588d86b7..116e90ecd75 100644 --- a/account_invoice_qr_code_sepa_payconiq/static/description/index.html +++ b/account_invoice_qr_code_sepa_payconiq/static/description/index.html @@ -1,20 +1,20 @@ - - + Account Invoice Qr Code Sepa Payconiq