forked from DGNum/gestioCOF
Merge branch 'Elarnon/do_resell' into 'master'
Supprime do_resell La fonction utilitaire `bda.views.do_resell` n’est plus utilisée depuis la nouvelle version de bda-revente. See merge request !111
This commit is contained in:
commit
2a4af5fcf4
1 changed files with 0 additions and 19 deletions
19
bda/views.py
19
bda/views.py
|
@ -263,25 +263,6 @@ def tirage(request, tirage_id):
|
||||||
return render(request, "bda-token.html", {"form": form})
|
return render(request, "bda-token.html", {"form": form})
|
||||||
|
|
||||||
|
|
||||||
def do_resell(request, form):
|
|
||||||
spectacle = form.cleaned_data["spectacle"]
|
|
||||||
count = form.cleaned_data["count"]
|
|
||||||
places = "2 places" if count == "2" else "une place"
|
|
||||||
mail = """Bonjour,
|
|
||||||
|
|
||||||
Je souhaite revendre %s pour %s le %s (%s) à %.02f€.
|
|
||||||
Contactez moi par email si vous êtes intéressé·e·s !
|
|
||||||
|
|
||||||
%s (%s)""" % (places, spectacle.title, spectacle.date_no_seconds(),
|
|
||||||
spectacle.location, spectacle.price,
|
|
||||||
request.user.get_full_name(), request.user.email)
|
|
||||||
send_mail("%s" % spectacle, mail,
|
|
||||||
request.user.email, ["bda-revente@lists.ens.fr"],
|
|
||||||
fail_silently=False)
|
|
||||||
return render(request, "bda-success.html",
|
|
||||||
{"show": spectacle, "places": places})
|
|
||||||
|
|
||||||
|
|
||||||
@login_required
|
@login_required
|
||||||
def revente(request, tirage_id):
|
def revente(request, tirage_id):
|
||||||
tirage = get_object_or_404(Tirage, id=tirage_id)
|
tirage = get_object_or_404(Tirage, id=tirage_id)
|
||||||
|
|
Loading…
Reference in a new issue