From: Matthijs Kooijman Date: Sun, 27 Jan 2008 16:02:32 +0000 (+0100) Subject: * Set a default value for the character_id argument to the add view. X-Git-Url: https://git.stderr.nl/gitweb?a=commitdiff_plain;h=f3dd167d45ba0e152ad19b1d37f4258e5a9d383f;p=matthijs%2Fprojects%2Fxerxes.git * Set a default value for the character_id argument to the add view. --- diff --git a/influences/views.py b/influences/views.py index 184a3a3..4df518f 100644 --- a/influences/views.py +++ b/influences/views.py @@ -21,7 +21,7 @@ class CharacterForm(ContextModelForm): model = Character fields = ('name') -def add(request, character_id): +def add(request, character_id=None): initial = {} # Get the current user's characters chars = request.user.character_set.all()