Ir al contenido
Menú
Se marcó esta pregunta

Hi,

I need a means to force user registration / login before a user is able to checkout in the eCommerce module. I've found some entry points on the topic for older Odoo versions but I need a solution for 10.

Help greatly appreciated!

Avatar
Descartar
Mejor respuesta

Hi,


Add a controller to change access

from odoo.addons.website_sale.controllers.main import WebsiteSale
from odoo import http

class SaleController(WebsiteSale):
    @http.route(auth='user')
    def checkout(self, **post):
         #the user is logged in to checkout
        return super(SaleController, self).checkout(**post)



Avatar
Descartar
Publicaciones relacionadas Respuestas Vistas Actividad
2
oct 19
5266
3
jul 23
27168
2
jun 22
5766
2
sept 21
4717
1
nov 20
8021