You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

16 lines
671 B

  1. # -*- coding: utf-8 -*-
  2. # (c) 2015 Antiun Ingeniería S.L. - Sergio Teruel
  3. # (c) 2015 Antiun Ingeniería S.L. - Carlos Dauden
  4. # © 2016 Jairo Llopis <jairo.llopis@tecnativa.com>
  5. # License AGPL-3 - See http://www.gnu.org/licenses/agpl-3.0.html
  6. from odoo.addons.auth_signup.controllers.main import AuthSignupHome
  7. from odoo.http import request
  8. class AuthSignupHome(AuthSignupHome):
  9. def _signup_with_values(self, token, values):
  10. account_type = request.params.get('account_type')
  11. if account_type in {"customer", "supplier"}:
  12. values.setdefault(account_type, True)
  13. return super(AuthSignupHome, self)._signup_with_values(token, values)