forked from DGNum/gestioCOF
Gestion de plus de deux places
This commit is contained in:
parent
175e2f7d67
commit
199895630e
1 changed files with 5 additions and 2 deletions
|
@ -334,8 +334,11 @@ def add_attrib(request, tirage_id, spectacle_id):
|
||||||
attrib = Attribution(participant=part, spectacle=spectacle,
|
attrib = Attribution(participant=part, spectacle=spectacle,
|
||||||
given=('given' in request.POST))
|
given=('given' in request.POST))
|
||||||
attrib.save()
|
attrib.save()
|
||||||
if request.POST['nb_places']==2:
|
if int(request.POST['nb_places'])==2:
|
||||||
attrib.save()
|
attrib2 = Attribution(participant=part, spectacle=spectacle,
|
||||||
|
given=('given' in request.POST))
|
||||||
|
attrib2.save()
|
||||||
|
|
||||||
messages.add_message(request, messages.SUCCESS,
|
messages.add_message(request, messages.SUCCESS,
|
||||||
"Attribution réussie !")
|
"Attribution réussie !")
|
||||||
return HttpResponseRedirect(reverse('bda-spectacle',
|
return HttpResponseRedirect(reverse('bda-spectacle',
|
||||||
|
|
Loading…
Reference in a new issue