[FIX] account: allow billing user to register payment difference

Currently, the register payment button in the invoice form view is
accessible to any Accounting/Billing user. But in the payment register
wizard, the payment difference related fields are only visible for an
Accounting/Auditor user. This does not make sense as the auditor access
level is a read-only role, and there is no dependency between auditor
and billing rights. We should remove the group (as it is already
restricted in the access rights of the model) in the wizard to allow
billing users to use the functionality without the need for accountant
access rights.

closes odoo/odoo#94380

X-original-commit: 488bda480a38f9c09496f770be8a6f540c541044
Signed-off-by: William André (wan) <wan@odoo.com>
Signed-off-by: Alex Thuyls (alt) <alt@odoo.com>
This commit is contained in:
alt-odoo
2022-06-23 06:57:03 +02:00
parent 038cdc66b9
commit 1d3879b6df
@@ -54,8 +54,7 @@
attrs="{'invisible': ['|', ('can_edit_wizard', '=', False), '&amp;', ('can_group_payments', '=', True), ('group_payment', '=', False)]}"/>
</group>
<group name="group3"
attrs="{'invisible': ['|', ('payment_difference', '=', 0.0), '|', ('can_edit_wizard', '=', False), '&amp;', ('can_group_payments', '=', True), ('group_payment', '=', False)]}"
groups="account.group_account_readonly">
attrs="{'invisible': ['|', ('payment_difference', '=', 0.0), '|', ('can_edit_wizard', '=', False), '&amp;', ('can_group_payments', '=', True), ('group_payment', '=', False)]}">
<label for="payment_difference"/>
<div>
<field name="payment_difference"/>