From 2643a6e6ba1e841cae9f95accf59939c0eb52d29 Mon Sep 17 00:00:00 2001 From: MuK IT GmbH Date: Thu, 29 Nov 2018 03:22:45 +0000 Subject: [PATCH] publish muk_web_theme - 12.0 --- muk_web_theme/models/res_config_settings.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/muk_web_theme/models/res_config_settings.py b/muk_web_theme/models/res_config_settings.py index eb4abda..28bffd8 100644 --- a/muk_web_theme/models/res_config_settings.py +++ b/muk_web_theme/models/res_config_settings.py @@ -75,8 +75,8 @@ class ResConfigSettings(models.TransientModel): custom_attachment = self._get_custom_attachment(custom_url) if custom_attachment.exists(): content = str(base64.b64decode(custom_attachment.datas)) - brand = re.match( r'o-brand-odoo\:?\s(.*?);', content) - primary = re.match( r'o-brand-primary\:?\s(.*?);', content) + brand = re.search( r'o-brand-odoo\:?\s(.*?);', content) + primary = re.search( r'o-brand-primary\:?\s(.*?);', content) return { 'theme_color_brand': brand and brand.group(1) or "#243742", 'theme_color_primary': primary and primary.group(1) or "#5D8DA8",