summaryrefslogtreecommitdiff
path: root/addons/auth_signup/controllers
diff options
context:
space:
mode:
authorRaphael Collet <rco@openerp.com>2016-11-22 12:04:09 +0100
committerRaphael Collet <rco@openerp.com>2017-01-03 16:52:49 +0100
commitd0ca2d115e8b40308e1ff83bf9e7cc874762fbff (patch)
treebdad5e8c9019f14a0416c27612969ae4932519b1 /addons/auth_signup/controllers
parent7543afb0704d624f7abe6a2450a9d7e4a75e158b (diff)
[REF] ir_config_parameter: remove `group_ids` and simplify
Add `sudo()` to call `get_param` where necessary, and make the web client use a controller instead of directly accessing parameters.
Diffstat (limited to 'addons/auth_signup/controllers')
-rw-r--r--addons/auth_signup/controllers/main.py6
1 files changed, 3 insertions, 3 deletions
diff --git a/addons/auth_signup/controllers/main.py b/addons/auth_signup/controllers/main.py
index 8a4315a0ad8..804642ac8c2 100644
--- a/addons/auth_signup/controllers/main.py
+++ b/addons/auth_signup/controllers/main.py
@@ -70,10 +70,10 @@ class AuthSignupHome(Home):
def get_auth_signup_config(self):
"""retrieve the module config (which features are enabled) for the login page"""
- IrConfigParam = request.env['ir.config_parameter'].sudo()
+ get_param = request.env['ir.config_parameter'].sudo().get_param
return {
- 'signup_enabled': IrConfigParam.get_param('auth_signup.allow_uninvited') == 'True',
- 'reset_password_enabled': IrConfigParam.get_param('auth_signup.reset_password') == 'True',
+ 'signup_enabled': get_param('auth_signup.allow_uninvited') == 'True',
+ 'reset_password_enabled': get_param('auth_signup.reset_password') == 'True',
}
def get_auth_signup_qcontext(self):