From bb1964b3e88a270b0bc1bc4405b20433205c1b7b Mon Sep 17 00:00:00 2001 From: Matthijs Kooijman Date: Thu, 24 Jan 2008 12:44:31 +0100 Subject: [PATCH] * Let the views in influences use RequestContext, so authentication data is properly exported. --- influences/views.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/influences/views.py b/influences/views.py index 41a1ecb..22f2a3b 100644 --- a/influences/views.py +++ b/influences/views.py @@ -1,5 +1,6 @@ from django.shortcuts import render_to_response from django.shortcuts import get_object_or_404 +from django.template import RequestContext from django.utils.translation import ugettext as _ from django.contrib.auth.models import User from ee.influences.models import Character @@ -38,7 +39,7 @@ def add(request, character_id): if f: f.fields['character']._set_queryset(chars) - return render_to_response('influences/add.html', {'message' : message, 'form' : f}) + return render_to_response('influences/add.html', {'message' : message, 'form' : f}, RequestContext(request)) def addCharacter(request): message = None @@ -55,4 +56,4 @@ def addCharacter(request): def index(request): characters = request.user.character_set.all() influences = Influence.objects.filter(character__in=characters) - return render_to_response('influences/index.html', {'characters' : characters, 'influences' : influences}) + return render_to_response('influences/index.html', {'characters' : characters, 'influences' : influences}, RequestContext(request)) -- 2.30.2