[IMP]pms: force company in folio invoice

This commit is contained in:
Darío Lodeiros
2022-01-08 18:06:48 +01:00
parent 3905e4ae2e
commit 591fafa9a1

View File

@@ -1641,9 +1641,13 @@ class PmsFolio(models.Model):
(making sure to call super() to establish a clean extension chain). (making sure to call super() to establish a clean extension chain).
""" """
self.ensure_one() self.ensure_one()
journal = ( journal = (
self.env["account.move"] self.env["account.move"]
.with_context(default_move_type="out_invoice") .with_context(
default_move_type="out_invoice",
default_company_id=self.company_id.id,
)
._get_default_journal() ._get_default_journal()
) )
if not journal: if not journal: