[IMP] account_payment_order: don't requiere reference_type anymore

This commit is contained in:
Miquel Raïch
2022-03-08 14:23:09 +01:00
committed by Pedro M. Baeza
parent 7e7ebe1c75
commit 62ca0b90f8
5 changed files with 44 additions and 61 deletions

View File

@@ -14,13 +14,13 @@ Account Payment Order
: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/14.0/account_payment_order
:target: https://github.com/OCA/bank-payment/tree/15.0/account_payment_order
: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-14-0/bank-payment-14-0-account_payment_order
:target: https://translation.odoo-community.org/projects/bank-payment-15-0/bank-payment-15-0-account_payment_order
: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/14.0
:target: https://runbot.odoo-community.org/runbot/173/15.0
:alt: Try me on Runbot
|badge1| |badge2| |badge3| |badge4| |badge5|
@@ -66,7 +66,7 @@ Bug Tracker
Bugs are tracked on `GitHub Issues <https://github.com/OCA/bank-payment/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 <https://github.com/OCA/bank-payment/issues/new?body=module:%20account_payment_order%0Aversion:%2014.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
`feedback <https://github.com/OCA/bank-payment/issues/new?body=module:%20account_payment_order%0Aversion:%2015.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**>`_.
Do not contact contributors directly about support or help with technical issues.
@@ -113,6 +113,7 @@ Contributors
* `Open Source Integrators <https://www.opensourceintegrators.com>`_:
* Ammar Officewala <aofficewala@opensourceintegrators.com>
* Marçal Isern <marsal.isern@qubiq.es>
Maintainers
~~~~~~~~~~~
@@ -127,6 +128,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-payment <https://github.com/OCA/bank-payment/tree/14.0/account_payment_order>`_ project on GitHub.
This module is part of the `OCA/bank-payment <https://github.com/OCA/bank-payment/tree/15.0/account_payment_order>`_ project on GitHub.
You are welcome to contribute. To learn how please visit https://odoo-community.org/page/Contribute.

View File

@@ -4,7 +4,7 @@
#
msgid ""
msgstr ""
"Project-Id-Version: Odoo Server 14.0\n"
"Project-Id-Version: Odoo Server 15.0\n"
"Report-Msgid-Bugs-To: \n"
"Last-Translator: \n"
"Language-Team: \n"
@@ -16,15 +16,16 @@ msgstr ""
#. module: account_payment_order
#: code:addons/account_payment_order/models/account_move.py:0
#, python-format
msgid "%d payment lines added to the existing draft payment order %s."
msgid ""
"%(count)d payment lines added to the existing draft payment order %(name)s."
msgstr ""
#. module: account_payment_order
#: code:addons/account_payment_order/models/account_move.py:0
#, python-format
msgid ""
"%d payment lines added to the new draft payment order %s which has been "
"automatically created."
"%(count)d payment lines added to the new draft payment order %(name)s which "
"has been automatically created."
msgstr ""
#. module: account_payment_order
@@ -66,7 +67,7 @@ msgstr ""
#: code:addons/account_payment_order/models/res_bank.py:0
#, python-format
msgid ""
"A valid BIC contains 8 or 11 characters. The BIC '%s' contains %d "
"A valid BIC contains 8 or 11 characters. The BIC '%(bic)s' contains %(num)d "
"characters, so it is not valid."
msgstr ""
@@ -208,7 +209,6 @@ msgstr ""
#: model:ir.actions.act_window,name:account_payment_order.bank_payment_line_action
#: model:ir.model,name:account_payment_order.model_bank_payment_line
#: model:ir.ui.menu,name:account_payment_order.bank_payment_line_menu
#: model_terms:ir.ui.view,arch_db:account_payment_order.bank_payment_line_tree
msgid "Bank Payment Lines"
msgstr ""
@@ -227,7 +227,9 @@ msgstr ""
#. module: account_payment_order
#: code:addons/account_payment_order/models/bank_payment_line.py:0
#, python-format
msgid "Can not reconcile: no move line for payment line %s of partner '%s'."
msgid ""
"Can not reconcile: no move line for payment line %(line)s of partner "
"'%(partner)s'."
msgstr ""
#. module: account_payment_order
@@ -246,8 +248,8 @@ msgstr ""
#: code:addons/account_payment_order/models/bank_payment_line.py:0
#, python-format
msgid ""
"Cannot delete a payment order line whose payment order is in state '%s'. You"
" need to cancel it first."
"Cannot delete a payment order line whose payment order is in state "
"'%(state)s'. You need to cancel it first."
msgstr ""
#. module: account_payment_order
@@ -407,18 +409,10 @@ msgstr ""
#. module: account_payment_order
#: model:ir.model.fields,field_description:account_payment_order.field_account_invoice_payment_line_multi__display_name
#: model:ir.model.fields,field_description:account_payment_order.field_account_journal__display_name
#: model:ir.model.fields,field_description:account_payment_order.field_account_move__display_name
#: model:ir.model.fields,field_description:account_payment_order.field_account_move_line__display_name
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment__display_name
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_line__display_name
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_line_create__display_name
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_method__display_name
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_mode__display_name
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_order__display_name
#: model:ir.model.fields,field_description:account_payment_order.field_bank_payment_line__display_name
#: model:ir.model.fields,field_description:account_payment_order.field_report_account_payment_order_print_account_payment_order_main__display_name
#: model:ir.model.fields,field_description:account_payment_order.field_res_bank__display_name
msgid "Display Name"
msgstr ""
@@ -482,11 +476,6 @@ msgstr ""
msgid "Followers"
msgstr ""
#. module: account_payment_order
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_order__message_channel_ids
msgid "Followers (Channels)"
msgstr ""
#. module: account_payment_order
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_order__message_partner_ids
msgid "Followers (Partners)"
@@ -496,8 +485,9 @@ msgstr ""
#: code:addons/account_payment_order/models/bank_payment_line.py:0
#, python-format
msgid ""
"For partner '%s', the account of the account move line to pay (%s) is "
"different from the account of of the transit move line (%s)."
"For partner '%(partner)s', the account of the account move line to pay "
"(%(line1)s) is different from the account of of the transit move line "
"(%(line2)s)."
msgstr ""
#. module: account_payment_order
@@ -553,20 +543,17 @@ msgstr ""
msgid "Group Transactions in Payment Orders"
msgstr ""
#. module: account_payment_order
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_order__has_message
msgid "Has Message"
msgstr ""
#. module: account_payment_order
#: model:ir.model.fields,field_description:account_payment_order.field_account_invoice_payment_line_multi__id
#: model:ir.model.fields,field_description:account_payment_order.field_account_journal__id
#: model:ir.model.fields,field_description:account_payment_order.field_account_move__id
#: model:ir.model.fields,field_description:account_payment_order.field_account_move_line__id
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment__id
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_line__id
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_line_create__id
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_method__id
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_mode__id
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_order__id
#: model:ir.model.fields,field_description:account_payment_order.field_bank_payment_line__id
#: model:ir.model.fields,field_description:account_payment_order.field_report_account_payment_order_print_account_payment_order_main__id
#: model:ir.model.fields,field_description:account_payment_order.field_res_bank__id
msgid "ID"
msgstr ""
@@ -674,18 +661,10 @@ msgstr ""
#. module: account_payment_order
#: model:ir.model.fields,field_description:account_payment_order.field_account_invoice_payment_line_multi____last_update
#: model:ir.model.fields,field_description:account_payment_order.field_account_journal____last_update
#: model:ir.model.fields,field_description:account_payment_order.field_account_move____last_update
#: model:ir.model.fields,field_description:account_payment_order.field_account_move_line____last_update
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment____last_update
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_line____last_update
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_line_create____last_update
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_method____last_update
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_mode____last_update
#: model:ir.model.fields,field_description:account_payment_order.field_account_payment_order____last_update
#: model:ir.model.fields,field_description:account_payment_order.field_bank_payment_line____last_update
#: model:ir.model.fields,field_description:account_payment_order.field_report_account_payment_order_print_account_payment_order_main____last_update
#: model:ir.model.fields,field_description:account_payment_order.field_res_bank____last_update
msgid "Last Modified on"
msgstr ""
@@ -775,7 +754,8 @@ msgstr ""
#. module: account_payment_order
#: code:addons/account_payment_order/models/bank_payment_line.py:0
#, python-format
msgid "Move line '%s' of partner '%s' has already been reconciled"
msgid ""
"Move line '%(line)s' of partner '%(partner)s' has already been reconciled"
msgstr ""
#. module: account_payment_order
@@ -848,7 +828,9 @@ msgstr ""
#. module: account_payment_order
#: code:addons/account_payment_order/models/account_payment_order.py:0
#, python-format
msgid "On payment order %s, the Payment Execution Date is in the past (%s)."
msgid ""
"On payment order %(porder)s, the Payment Execution Date is in the past "
"(%(exedate)s)."
msgstr ""
#. module: account_payment_order
@@ -941,7 +923,6 @@ msgstr ""
#: model:ir.model,name:account_payment_order.model_account_payment_line
#: model:ir.model.fields,field_description:account_payment_order.field_bank_payment_line__payment_line_ids
#: model_terms:ir.ui.view,arch_db:account_payment_order.account_payment_line_form
#: model_terms:ir.ui.view,arch_db:account_payment_order.account_payment_line_tree
msgid "Payment Lines"
msgstr ""
@@ -997,7 +978,6 @@ msgstr ""
#: model:ir.ui.menu,name:account_payment_order.account_payment_order_outbound_menu
#: model_terms:ir.ui.view,arch_db:account_payment_order.account_payment_order_graph
#: model_terms:ir.ui.view,arch_db:account_payment_order.account_payment_order_pivot
#: model_terms:ir.ui.view,arch_db:account_payment_order.account_payment_order_tree
msgid "Payment Orders"
msgstr ""
@@ -1144,7 +1124,8 @@ msgstr ""
#. module: account_payment_order
#: code:addons/account_payment_order/models/account_payment_order.py:0
#, python-format
msgid "The amount for Partner '%s' is negative or null (%.2f) !"
msgid ""
"The amount for Partner '%(partner)s' is negative or null (%(amount).2f) !"
msgstr ""
#. module: account_payment_order
@@ -1167,17 +1148,17 @@ msgstr ""
#: code:addons/account_payment_order/models/account_payment_order.py:0
#, python-format
msgid ""
"The payment mode '%s' has the option 'Disallow Debit Before Maturity Date'. "
"The payment line %s has a maturity date %s which is after the computed "
"payment date %s."
"The payment mode '%(pmode)s' has the option 'Disallow Debit Before Maturity "
"Date'. The payment line %(pline)s has a maturity date %(mdate)s which is "
"after the computed payment date %(pdate)s."
msgstr ""
#. module: account_payment_order
#: code:addons/account_payment_order/models/account_payment_order.py:0
#, python-format
msgid ""
"The payment type (%s) is not the same as the payment type of the payment "
"mode (%s)"
"The payment type (%(ptype)s) is not the same as the payment type of the "
"payment mode (%(pmode)s)"
msgstr ""
#. module: account_payment_order

View File

@@ -57,7 +57,7 @@ class AccountMoveLine(models.Model):
communication = self.ref or self.name
# change these default values if move line is linked to an invoice
if self.move_id.is_invoice():
if self.move_id.reference_type != "none":
if (self.move_id.reference_type or "none") != "none":
communication = self.move_id.ref
ref2comm_type = aplo.invoice_reference_type2communication_type()
communication_type = ref2comm_type[self.move_id.reference_type]

View File

@@ -367,7 +367,7 @@ ul.auto-toc {
!! This file is generated by oca-gen-addon-readme !!
!! changes will be overwritten. !!
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
<p><a class="reference external" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external" href="http://www.gnu.org/licenses/agpl-3.0-standalone.html"><img alt="License: AGPL-3" src="https://img.shields.io/badge/licence-AGPL--3-blue.png" /></a> <a class="reference external" href="https://github.com/OCA/bank-payment/tree/14.0/account_payment_order"><img alt="OCA/bank-payment" src="https://img.shields.io/badge/github-OCA%2Fbank--payment-lightgray.png?logo=github" /></a> <a class="reference external" href="https://translation.odoo-community.org/projects/bank-payment-14-0/bank-payment-14-0-account_payment_order"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external" href="https://runbot.odoo-community.org/runbot/173/14.0"><img alt="Try me on Runbot" src="https://img.shields.io/badge/runbot-Try%20me-875A7B.png" /></a></p>
<p><a class="reference external" href="https://odoo-community.org/page/development-status"><img alt="Beta" src="https://img.shields.io/badge/maturity-Beta-yellow.png" /></a> <a class="reference external" href="http://www.gnu.org/licenses/agpl-3.0-standalone.html"><img alt="License: AGPL-3" src="https://img.shields.io/badge/licence-AGPL--3-blue.png" /></a> <a class="reference external" href="https://github.com/OCA/bank-payment/tree/15.0/account_payment_order"><img alt="OCA/bank-payment" src="https://img.shields.io/badge/github-OCA%2Fbank--payment-lightgray.png?logo=github" /></a> <a class="reference external" href="https://translation.odoo-community.org/projects/bank-payment-15-0/bank-payment-15-0-account_payment_order"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external" href="https://runbot.odoo-community.org/runbot/173/15.0"><img alt="Try me on Runbot" src="https://img.shields.io/badge/runbot-Try%20me-875A7B.png" /></a></p>
<p>This module adds support for payment orders and debit orders.</p>
<p><strong>Table of contents</strong></p>
<div class="contents local topic" id="contents">
@@ -411,7 +411,7 @@ Configuration &gt; Management &gt; Payment Modes.</p>
<p>Bugs are tracked on <a class="reference external" href="https://github.com/OCA/bank-payment/issues">GitHub Issues</a>.
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
<a class="reference external" href="https://github.com/OCA/bank-payment/issues/new?body=module:%20account_payment_order%0Aversion:%2014.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
<a class="reference external" href="https://github.com/OCA/bank-payment/issues/new?body=module:%20account_payment_order%0Aversion:%2015.0%0A%0A**Steps%20to%20reproduce**%0A-%20...%0A%0A**Current%20behavior**%0A%0A**Expected%20behavior**">feedback</a>.</p>
<p>Do not contact contributors directly about support or help with technical issues.</p>
</div>
<div class="section" id="credits">
@@ -460,6 +460,7 @@ If you spotted it first, help us smashing it by providing a detailed and welcome
<li>Ammar Officewala &lt;<a class="reference external" href="mailto:aofficewala&#64;opensourceintegrators.com">aofficewala&#64;opensourceintegrators.com</a>&gt;</li>
</ul>
</li>
<li>Marçal Isern &lt;<a class="reference external" href="mailto:marsal.isern&#64;qubiq.es">marsal.isern&#64;qubiq.es</a>&gt;</li>
</ul>
</div>
<div class="section" id="maintainers">
@@ -469,7 +470,7 @@ If you spotted it first, help us smashing it by providing a detailed and welcome
<p>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.</p>
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/bank-payment/tree/14.0/account_payment_order">OCA/bank-payment</a> project on GitHub.</p>
<p>This module is part of the <a class="reference external" href="https://github.com/OCA/bank-payment/tree/15.0/account_payment_order">OCA/bank-payment</a> project on GitHub.</p>
<p>You are welcome to contribute. To learn how please visit <a class="reference external" href="https://odoo-community.org/page/Contribute">https://odoo-community.org/page/Contribute</a>.</p>
</div>
</div>

View File

@@ -45,9 +45,9 @@
<field name="payment_reference" position="before">
<field
name="reference_type"
required="1"
attrs="{'readonly':[('state','!=','draft')],
'invisible': [('move_type', 'not in', ('out_invoice', 'out_refund'))]}"
'invisible': [('move_type', 'not in', ('out_invoice', 'out_refund'))],
'required': [('move_type', 'in', ('out_invoice', 'out_refund'))]}"
/>
</field>
</field>