From 028c99db68cc2bc91c9e993f68afe35ad936d67c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Thibault=20Delavall=C3=A9e?= Date: Fri, 8 Sep 2017 17:00:09 +0200 Subject: [PATCH] [FIX] auth_signup: open correct user for access rights in settings Actually the signup template user to open is configurable and come from an ir.config_parameter and is not necessarily the data created in auth_signup even if it is the default value. --- addons/auth_signup/models/base_config_settings.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/addons/auth_signup/models/base_config_settings.py b/addons/auth_signup/models/base_config_settings.py index 8e8999d91a7..81736c0fc07 100644 --- a/addons/auth_signup/models/base_config_settings.py +++ b/addons/auth_signup/models/base_config_settings.py @@ -40,6 +40,6 @@ class BaseConfigSettings(models.TransientModel): @api.multi def open_template_user(self): action = self.env.ref('base.action_res_users').read()[0] - action['res_id'] = self.env.ref('auth_signup.default_template_user').id + action['res_id'] = literal_eval(self.env['ir.config_parameter'].sudo().get_param('auth_signup.template_user_id', 'False')) action['views'] = [[self.env.ref('base.view_users_form').id, 'form']] return action