You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
90 lines
2.7 KiB
90 lines
2.7 KiB
{% extends 'tournaments/base.html' %}
|
|
|
|
{% block head_title %}{{ tournament.display_name }} : Informations{% endblock %}
|
|
{% block first_title %}{{ tournament.event.display_name }}{% endblock %}
|
|
{% block second_title %}{{ tournament.display_name }}{% endblock %}
|
|
|
|
{% block content %}
|
|
{% load static %}
|
|
{% load tz %}
|
|
|
|
<nav class="margin10">
|
|
<a href="{% url 'tournament-info' tournament.id %}" class="topmargin5">Informations</a>
|
|
</nav>
|
|
|
|
<div class="grid-x">
|
|
|
|
<div class="cell medium-6 large-6 my-block">
|
|
<h1 class="club my-block topmargin20">Inscription au {{ tournament.display_name }} {{ tournament.get_federal_age_category_display}}</h1 >
|
|
|
|
|
|
<div class="bubble">
|
|
|
|
{% if registration_successful %}
|
|
<p>Merci, l'inscription a bien été envoyé au juge-arbitre.</p>
|
|
|
|
{% else %}
|
|
<form method="post">
|
|
{% csrf_token %}
|
|
|
|
<!-- Team Registration Form -->
|
|
<div>
|
|
<p>
|
|
<div class="semibold">
|
|
Informations de contact
|
|
</div>
|
|
</p>
|
|
{{ team_form.as_p }} <!-- Render team registration form fields here -->
|
|
</div>
|
|
|
|
<!-- Show players added to the team only if there are players added -->
|
|
{% if current_players %}
|
|
<p>
|
|
<div class="semibold">
|
|
Constitution de votre équipe
|
|
</div>
|
|
</p>
|
|
<ul>
|
|
{% for player in current_players %}
|
|
<li>{{ player.first_name }} {{ player.last_name }} ({{ player.licence_id }})</li>
|
|
{% endfor %}
|
|
</ul>
|
|
{% endif %}
|
|
|
|
<!-- Add Player Form -->
|
|
{% if current_players|length < 2 %}
|
|
<div>
|
|
{{ add_player_form.licence_id.label_tag }}
|
|
{{ add_player_form.licence_id }}
|
|
{% if add_player_form.first_tournament %}
|
|
Précisez les informations du joueur :
|
|
{{ add_player_form.first_name.label_tag }}
|
|
{{ add_player_form.first_name }}
|
|
{{ add_player_form.last_name.label_tag }}
|
|
{{ add_player_form.last_name }}
|
|
{% endif %}
|
|
|
|
<button type="submit" name="add_player" class="button">Ajouter un joueur</button>
|
|
</div>
|
|
{% endif %}
|
|
|
|
<!-- Show players added to the team only if there are players added -->
|
|
{% if current_players|length >= 2 %}
|
|
<button type="submit" name="register_team" class="button">Confirmer l'inscription</button>
|
|
{% endif %}
|
|
</form>
|
|
|
|
{% if registration_successful %}
|
|
<p>Registration was successful! Your team and players have been registered.</p>
|
|
{% endif %}
|
|
|
|
|
|
{% for message in messages %}
|
|
<div class="alert alert-{{ message.tags }}">{{ message }}</div>
|
|
{% endfor %}
|
|
|
|
{% endif %}
|
|
</div>
|
|
</div>
|
|
</div>
|
|
{% endblock %}
|
|
|