import json from odoo import http from odoo.exceptions import UserError from odoo.http import request from odoo.addons.auth_signup.controllers.main import AuthSignupHome from odoo.addons.website_sale.controllers.main import WebsiteSale class AuthSignupHome(AuthSignupHome): def do_signup(self, qcontext): # add more fileds to the list after the phone values = {key: qcontext.get(key) for key in ('login', 'name', 'password', 'phone','your_field_goes_here')} if not values: raise UserError(_("The form was not properly filled in.")) if values.get('password') != qcontext.get('confirm_password'): raise UserError(_("Passwords do not match; please retype them.")) supported_lang_codes = [code for code, _ in request.env['res.lang'].get_installed()] lang = request.context.get('lang', '').split('_')[0] if lang in supported_lang_codes: values['lang'] = lang self._signup_with_values(qcontext.get('token'), values) request.env.cr.commit() class WebsiteSale(WebsiteSale): # add more fileds to the list if you want them to be mandetory def _get_mandatory_shipping_fields(self): return ["name"] def _get_mandatory_billing_fields(self): return ["name", "email"]