Skip to content

Commit 3cfd626

Browse files
[MIG] account_invoice_block_payment: Migration to 18.0
1 parent 8dafc35 commit 3cfd626

File tree

8 files changed

+19
-10
lines changed

8 files changed

+19
-10
lines changed

account_invoice_block_payment/README.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ Account Invoice Payment Block
77
!! This file is generated by oca-gen-addon-readme !!
88
!! changes will be overwritten. !!
99
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
10-
!! source digest: sha256:c3e9bc1d75a9bd7ebb64df35b4a09230431ec8c6115aa7ac5a7219c4e3b4dc89
10+
!! source digest: sha256:189d9f5529777ab9e032d084ce9e6e199d5e9adff15ab8c7708968b73f3e5a56
1111
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
1212
1313
.. |badge1| image:: https://img.shields.io/badge/maturity-Beta-yellow.png

account_invoice_block_payment/__manifest__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33

44
{
55
"name": "Account Invoice Payment Block",
6-
"version": "16.0.1.0.0",
6+
"version": "18.0.1.0.0",
77
"summary": "Module to block payment of invoices",
88
"author": "Camptocamp, Odoo Community Association (OCA)",
99
"website": "https://github.com/OCA/account-invoicing",

account_invoice_block_payment/i18n/account_invoice_block_payment.pot

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@
44
#
55
msgid ""
66
msgstr ""
7-
"Project-Id-Version: Odoo Server 16.0\n"
7+
"Project-Id-Version: Odoo Server 17.0\n"
88
"Report-Msgid-Bugs-To: \n"
99
"Last-Translator: \n"
1010
"Language-Team: \n"

account_invoice_block_payment/i18n/it.po

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,9 +4,9 @@
44
#
55
msgid ""
66
msgstr ""
7-
"Project-Id-Version: Odoo Server 16.0\n"
7+
"Project-Id-Version: Odoo Server 17.0\n"
88
"Report-Msgid-Bugs-To: \n"
9-
"PO-Revision-Date: 2024-09-05 10:06+0000\n"
9+
"PO-Revision-Date: 2024-09-04 10:06+0000\n"
1010
"Last-Translator: mymage <[email protected]>\n"
1111
"Language-Team: none\n"
1212
"Language: it\n"
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
- Victor Vermot-Petit-Outhenin \<[email protected]\>
1+
- Victor Vermot-Petit-Outhenin \<<[email protected]>\>

account_invoice_block_payment/static/description/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -367,7 +367,7 @@ <h1 class="title">Account Invoice Payment Block</h1>
367367
!! This file is generated by oca-gen-addon-readme !!
368368
!! changes will be overwritten. !!
369369
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!
370-
!! source digest: sha256:c3e9bc1d75a9bd7ebb64df35b4a09230431ec8c6115aa7ac5a7219c4e3b4dc89
370+
!! source digest: sha256:189d9f5529777ab9e032d084ce9e6e199d5e9adff15ab8c7708968b73f3e5a56
371371
!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!! -->
372372
<p><a class="reference external image-reference" 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 image-reference" 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 image-reference" href="https://github.com/OCA/account-invoicing/tree/18.0/account_invoice_block_payment"><img alt="OCA/account-invoicing" src="https://img.shields.io/badge/github-OCA%2Faccount--invoicing-lightgray.png?logo=github" /></a> <a class="reference external image-reference" href="https://translation.odoo-community.org/projects/account-invoicing-18-0/account-invoicing-18-0-account_invoice_block_payment"><img alt="Translate me on Weblate" src="https://img.shields.io/badge/weblate-Translate%20me-F47D42.png" /></a> <a class="reference external image-reference" href="https://runboat.odoo-community.org/builds?repo=OCA/account-invoicing&amp;target_branch=18.0"><img alt="Try me on Runboat" src="https://img.shields.io/badge/runboat-Try%20me-875A7B.png" /></a></p>
373373
<div class="section" id="block-payment-of-invoices">

account_invoice_block_payment/tests/test_account_block_payment.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,7 @@ def setUpClass(cls):
1515
def test_payment_blocked(self):
1616
# Blocked boolean set to true rises a ValidationError
1717
self.assertFalse(self.account_move.payment_blocked)
18+
self.account_move.action_post()
1819
self.account_move.payment_blocked = True
1920
with self.assertRaises(UserError):
2021
self.account_move.action_register_payment()

account_invoice_block_payment/views/account_move.xml

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
<?xml version="1.0" encoding="utf-8" ?>
1+
<?xml version="1.0" ?>
22
<!-- Copyright 2023 Camptocamp SA
33
License AGPL-3.0 or later (http://www.gnu.org/licenses/agpl.html) -->
44
<odoo>
@@ -9,8 +9,16 @@
99
<field name="payment_reference" position="after">
1010
<field
1111
name="payment_blocked"
12-
attrs="{'invisible': ['|', '|', ('state', '!=', 'posted'), ('payment_state', 'not in', ('not_paid', 'partial')),
13-
('move_type', 'not in', ('out_invoice', 'out_refund', 'in_invoice', 'in_refund', 'out_receipt', 'in_receipt'))]}"
12+
invisible="state != 'posted'
13+
or payment_state not in ('not_paid', 'partial')
14+
or move_type not in (
15+
'out_invoice',
16+
'out_refund',
17+
'in_invoice',
18+
'in_refund',
19+
'out_receipt',
20+
'in_receipt'
21+
)"
1422
/>
1523
</field>
1624
</field>

0 commit comments

Comments
 (0)