[FIX] Add check_company=True on contracts and contract lines

Add check_company=True in field definition and
[('company_id', '=', company_id)] in the domain (in view or in field definition)
This commit is contained in:
Alexis de Lattre
2022-05-09 14:35:04 +02:00
parent 8409479cbe
commit 000ad9eabb
11 changed files with 50 additions and 6 deletions

View File

@@ -14,6 +14,7 @@ class ContractContract(models.Model):
help="If mandate required in payment method and not set mandate, "
"invoice takes the first valid mandate",
index=True,
check_company=True,
)
mandate_required = fields.Boolean(
related="payment_mode_id.payment_method_id.mandate_required", readonly=True