Restrict direct debit reception to receivable accounts

Closes #15059
This commit is contained in:
Adrià Tarroja Caubet
2026-09-03 15:56:17 +02:00
parent 84dc3f95cf
commit 39033df41c
2 changed files with 2 additions and 5 deletions
+1 -4
View File
@@ -267,10 +267,7 @@ class MoveLine(metaclass=PoolMeta):
@classmethod
def _pay_direct_debit_domain(cls, date):
return [
['OR',
('account.type.receivable', '=', True),
('account.type.payable', '=', True),
],
('account.type.receivable', '=', True),
('party.reception_direct_debits', '!=', None),
('reconciliation', '=', None),
('payment_amount', '!=', 0),
+1 -1
View File
@@ -9,7 +9,7 @@ this repository contains the full copyright notices and license terms. -->
<field name="name">Receivable with Mandate</field>
<field name="sequence" eval="25"/>
<field name="domain"
eval="['AND', ['OR', ('debit', '&gt;', 0), ('credit', '&lt;', 0)], ('party.sepa_mandates.state', '=', 'validated')]"
eval="['AND', ('account.type.receivable', '=', True), ['OR', ('debit', '&gt;', 0), ('credit', '&lt;', 0)], ('party.sepa_mandates.state', '=', 'validated')]"
pyson="1"/>
<field name="count" eval="True"/>
<field name="act_window" ref="account_payment.act_move_line_form"/>