From 82ae8761b06f61d10515a6c195c301192e53a10e Mon Sep 17 00:00:00 2001 From: Guillaume MASSON Date: Tue, 31 Oct 2023 10:38:44 +0100 Subject: [PATCH] [IMP] brand_external_report_layout : keep original company for reports and just temporarily use brand data - do not use company details and footer from brand, so that it could be used in multi-company - this avoid conflicts with other modules overriding company to add information in reports Fixes #167 Fixes #179 --- brand_external_report_layout/wizards/brand_document_layout.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/brand_external_report_layout/wizards/brand_document_layout.py b/brand_external_report_layout/wizards/brand_document_layout.py index 8675ee75e..17f9a9676 100644 --- a/brand_external_report_layout/wizards/brand_document_layout.py +++ b/brand_external_report_layout/wizards/brand_document_layout.py @@ -21,7 +21,7 @@ class BrandDocumentLayout(models.TransientModel): logo = fields.Binary(related="brand_id.logo", readonly=False) report_header = fields.Html(related="brand_id.report_header", readonly=False) - report_footer = fields.Html(readonly=True) + report_footer = fields.Html(default=None, readonly=True) paperformat_id = fields.Many2one(related="brand_id.paperformat_id", readonly=False) external_report_layout_id = fields.Many2one( related="brand_id.external_report_layout_id", readonly=False @@ -30,7 +30,7 @@ class BrandDocumentLayout(models.TransientModel): font = fields.Selection(related="brand_id.font", readonly=False) primary_color = fields.Char(related="brand_id.primary_color", readonly=False) secondary_color = fields.Char(related="brand_id.secondary_color", readonly=False) - company_details = fields.Html(readonly=True) + company_details = fields.Html(default=None, readonly=True) layout_background = fields.Selection( related="brand_id.layout_background", readonly=False )