mirror of
https://gitlab.com/animath/si/plateforme.git
synced 2025-06-21 21:58:25 +02:00
Display teams
This commit is contained in:
49
templates/tournament/team_detail.html
Normal file
49
templates/tournament/team_detail.html
Normal file
@ -0,0 +1,49 @@
|
||||
{% extends "base.html" %}
|
||||
|
||||
{% load getconfig i18n django_tables2 static %}
|
||||
|
||||
{% block content %}
|
||||
<div class="card bg-light shadow">
|
||||
<div class="card-header text-center">
|
||||
<h4>{% trans "Team" %} {{ team.name }}</h4>
|
||||
</div>
|
||||
<div class="card-body">
|
||||
<dl class="row">
|
||||
<dt class="col-xl-6 text-right">{% trans 'name'|capfirst %}</dt>
|
||||
<dd class="col-xl-6">{{ team.name }}</dd>
|
||||
|
||||
<dt class="col-xl-6 text-right">{% trans 'trigram'|capfirst %}</dt>
|
||||
<dd class="col-xl-6">{{ team.trigram }}</dd>
|
||||
|
||||
<dt class="col-xl-6 text-right">{% trans 'tournament'|capfirst %}</dt>
|
||||
<dd class="col-xl-6">{{ team.tournament }}</dd>
|
||||
|
||||
<dt class="col-xl-6 text-right">{% trans 'coachs'|capfirst %}</dt>
|
||||
<dd class="col-xl-6">{{ team.encadrants.all|join:", " }}</dd>
|
||||
|
||||
<dt class="col-xl-6 text-right">{% trans 'participants'|capfirst %}</dt>
|
||||
<dd class="col-xl-6">{{ team.participants.all|join:", " }}</dd>
|
||||
</dl>
|
||||
</div>
|
||||
|
||||
{% if user.admin or user in team.tournament.organizers.all %}
|
||||
<div class="card-footer text-center">
|
||||
<button class="btn btn-secondary">{% trans "Edit team" %}</button>
|
||||
{% if user.admin and team.invalid %}
|
||||
<button class="btn btn-danger">{% trans "Delete team" %}</button>
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
|
||||
<hr>
|
||||
|
||||
<h4>{% trans "Documents" %}</h4>
|
||||
|
||||
{% if team.motivation_letters %}
|
||||
<div class="alert alert-info">
|
||||
{% blocktrans with version=team.motivation_letters.count %}Motivation letter (version {{ version }}):{% endblocktrans %}
|
||||
<a href="{{ team.motivation_letters.last.file.url }}">{% trans "Download" %}</a>
|
||||
</div>
|
||||
{% endif %}
|
||||
{% endblock %}
|
@ -54,6 +54,7 @@
|
||||
|
||||
<hr>
|
||||
|
||||
<h3>{% trans "Teams" %}</h3>
|
||||
<div id="teams_table">
|
||||
{% render_table teams %}
|
||||
</div>
|
||||
|
Reference in New Issue
Block a user