SOITA/templates/createTournament.html
2022-06-05 10:27:49 +02:00

41 lines
1.4 KiB
HTML

{% extends "base.html" %}
{% load rest_framework %}
{% block title %}Stwórz turniej{% endblock %}
{% block content %}
<h1>Stwórz turniej</h1>
<form method="post" novalidate>
<span>Nazwa turnieju:<input id="name" type="text" name="name" value="{{ tournament.name }}"></span><br>
<span>Próg zdawalności:<input id="passing_score" type="text" name="passing_score" value="{{ tournament.passing_score }}"></span>
{% for question in questions %}
<div class="tournamentQuestionContainer">
<div class="mainTestName">
<div class="question_title" style="padding-top:15px; padding-bottom:10px; padding-left:5px;">
<input class="form-check-input me-1" type="radio" name={{ question.id }} value={{ question.id }}>
{{ question.description }}
</div>
<div class="list-group">
{% for answer in question.answers.all %}
<label class="list-group-item">
- {{ answer.description }}<br>
</label>
{% endfor %}
</div>
</div>
</div>
{% endfor %}
<div class="testContent">
<input type="submit" value="Stwórz turniej">
</div>
</form>
{% endblock %}