Skip to content

Commit

Permalink
valeur par defaut de la source au valido
Browse files Browse the repository at this point in the history
  • Loading branch information
dralliw committed Jul 7, 2014
1 parent e7c940a commit da76d81
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion zds/tutorial/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -702,7 +702,10 @@ def view_tutorial(request, tutorial_pk, tutorial_slug):
.order_by("-date_proposition")\
.first()
formAskValidation = AskValidationForm()
formValid = ValidForm()
if tutorial.source:
formValid = ValidForm(initial={"source": tutorial.source})
else:
formValid = ValidForm()
formReject = RejectForm()
return render_template("tutorial/tutorial/view.html", {
"tutorial": tutorial,
Expand Down

0 comments on commit da76d81

Please sign in to comment.