Skip to Content
Menu
This question has been flagged
1 Reply
4363 Views

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
Discard
Related Posts Replies Views Activity
4
May 21
19093
0
Jun 20
2227
1
Nov 18
4622
0
May 16
2918
6
Feb 16
11020