From 43d91c289a79a6b3f099596d8e8f1ffb835f3de6 Mon Sep 17 00:00:00 2001 From: Julien Mougenot Date: Mon, 16 Sep 2019 14:30:07 +0000 Subject: [PATCH] [FIX] base: document layout reset colors button Fixed the button allowing to reset to the logo colors in the document layout configurator. Before this commit, the custom_colors boolean asserting that the colors used by the layout are different than the ones computed from the logo and used to revert to those colors was in readonly and couldn't be toggled. Now, the boolean is editable and allows to revert the colors properly. Task 2072557 closes odoo/odoo#36968 Signed-off-by: VincentSchippefilt --- odoo/addons/base/wizard/base_document_layout.py | 2 +- odoo/addons/base/wizard/base_document_layout_views.xml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/odoo/addons/base/wizard/base_document_layout.py b/odoo/addons/base/wizard/base_document_layout.py index 00d6cbd7883..afbe91f3c8e 100644 --- a/odoo/addons/base/wizard/base_document_layout.py +++ b/odoo/addons/base/wizard/base_document_layout.py @@ -28,7 +28,7 @@ class BaseDocumentLayout(models.TransientModel): primary_color = fields.Char(related='company_id.primary_color', readonly=False) secondary_color = fields.Char(related='company_id.secondary_color', readonly=False) - custom_colors = fields.Boolean(compute="_compute_custom_colors") + custom_colors = fields.Boolean(compute="_compute_custom_colors", readonly=False) logo_primary_color = fields.Char(compute="_compute_logo_colors") logo_secondary_color = fields.Char(compute="_compute_logo_colors") diff --git a/odoo/addons/base/wizard/base_document_layout_views.xml b/odoo/addons/base/wizard/base_document_layout_views.xml index 8cb49407f05..53f76eb34be 100644 --- a/odoo/addons/base/wizard/base_document_layout_views.xml +++ b/odoo/addons/base/wizard/base_document_layout_views.xml @@ -19,7 +19,7 @@
-