From 7311b698a29143a599e2de69d2e0b97cbe3bd1d8 Mon Sep 17 00:00:00 2001 From: Denis Ledoux Date: Tue, 1 Oct 2013 19:30:20 +0200 Subject: [PATCH] [FIX]portal: previous commit was wrong. I was distracted. auth_signup do not depends on share, portal is, so moving the values['share'] = true to portal module bzr revid: dle@openerp.com-20131001173020-kv8upxloazihz5uh --- addons/auth_signup/res_users.py | 1 - addons/portal/portal.py | 6 ++++++ 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/addons/auth_signup/res_users.py b/addons/auth_signup/res_users.py index 9dd5090a03e..e29d55ba47b 100644 --- a/addons/auth_signup/res_users.py +++ b/addons/auth_signup/res_users.py @@ -227,7 +227,6 @@ class res_users(osv.Model): # create a copy of the template user (attached to a specific partner_id if given) values['active'] = True - values['share'] = True return self.copy(cr, uid, template_user_id, values, context=context) def reset_password(self, cr, uid, login, context=None): diff --git a/addons/portal/portal.py b/addons/portal/portal.py index 3e43e1a4424..bbab8b16cd3 100644 --- a/addons/portal/portal.py +++ b/addons/portal/portal.py @@ -31,3 +31,9 @@ class portal(osv.osv): 'is_portal': fields.boolean('Portal', help="If checked, this group is usable as a portal."), } +class res_users(osv.Model): + _inherit = 'res.users' + def _signup_create_user(self, cr, uid, values, context=None): + values['share'] = True + return super(res_users, self)._signup_create_user(cr, uid, values, context=context) +