def get_context_data(self, **kwargs): context = super(WhatIsNewListView, self).get_context_data(**kwargs) context['latest'] = NewStuff.objects.all() context['now'] = timezone.now() context['is_staff'] = get_current_user().is_staff if settings.DEBUG: print("is staff?", context['is_staff']) return context
def get_context_data(self, **kwargs): context = super(WhatIsNewDeleteView, self).get_context_data(**kwargs) context['is_staff'] = get_current_user().is_staff if settings.DEBUG: print("Delete View: is staff?", context['is_staff']) return context