Skip to Content
Menú
This question has been flagged
1 Respondre
5093 Vistes

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
Related Posts Respostes Vistes Activitat
4
d’ag. 25
20001
0
de juny 20
2741
1
de nov. 18
5164
0
de maig 16
3492
6
de febr. 16
11625