Reputation: 24749
In my views.py file on my Django site, I have a class based view that needs to alter a variable based on the user's permissions.
So if a user has the pro_view
permission, then it sees one thing. Otherwise if it has basic_view
then it sees another.
How can I access this inside my get_context_data(self, **kwargs):
function?
Upvotes: 6
Views: 3010