Ir al contenido
Menú
Se marcó esta pregunta
1 Responder
4632 Vistas

I would like to restrict access for static pages (ex. /contactus), to allow it only for authenticated users, I have tried updating the index method on the website addon, to use auth="user" instead of auth="public", but it is not working:

class RestrictWebsite(Website):
@http.route(auth="user")
def index(self):
return super(RestrictWebsite, self).index()
Avatar
Descartar
Publicaciones relacionadas Respuestas Vistas Actividad
4
may 21
19299
0
jun 20
2403
1
nov 18
4776
0
may 16
3000
6
feb 16
11178