Update gymnast note tab and note details
This commit is contained in:
parent
b8ab1b3242
commit
e8c8c2f52b
|
@ -27,7 +27,7 @@
|
|||
<h4 class=""><i class="text-primary fal fa-laugh-wink"></i> Hi {{ user.username }} !</h4>
|
||||
</div>
|
||||
<div class="card-body text-justify">
|
||||
<p>Welcome to Jarvi v0.82 <span class="text-muted">(last update : 20-05-2023)</span></p>
|
||||
<p>Welcome to Jarvi v0.83 <span class="text-muted">(last update : 12-06-2023)</span></p>
|
||||
<p>This application is here to help coaches to manage the gymnasts (evolution, evaluation, routines, scores, …). This tool is not perfect so feel free to make improvement proposals, bug reports, … by sending me an <a href="mailto:gregory@flyingacrobaticstrampoline.be">email</a>.</p>
|
||||
<p>You can find the user manuel <a href="{% static "files/Manuel_Utilisateur.pdf" %}" download>here (in french)</a>.</p>
|
||||
</div>
|
||||
|
|
|
@ -3,8 +3,8 @@
|
|||
{% block content %}
|
||||
<div class="card mb-0">
|
||||
<div class="card-header">
|
||||
<h3 class="mb-0"><a href="{% url 'gymnast_details_tab' note.gymnast.id 'scores' %}">{{ note.gymnast }}</a></h3>
|
||||
<h4 class="card-title"> Note of {{ note.created_at | date:'d-m-Y' }}</h4>
|
||||
<h3 class="mb-0"><a href="{% url 'gymnast_details_tab' note.gymnast.id 'scores' %}">{{ note.gymnast }}</a> - {{ note.title }}</h3>
|
||||
<p class="card-title text-muted"><b>{{ note.date | date:'j N Y' }}</b></p>
|
||||
</div>
|
||||
<div class="card-body pb-0 mb-0">
|
||||
<div class="row mr-1 ml-1 pb-0 mb-0">
|
||||
|
|
|
@ -5,7 +5,8 @@
|
|||
<div class="col-md-12">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h4>Latest note ({{ latest_published_note.date | date:'d-m-Y' }})</h4>
|
||||
<h4 class="mb-0">{{ latest_published_note.title }}</h4>
|
||||
<p class="text-muted">{{ latest_published_note.date | date:'j N Y' }}</p>
|
||||
</div>
|
||||
<div class="card-body pt-0">
|
||||
<p>{{ latest_published_note.to_markdown | safe }}</p>
|
||||
|
@ -53,14 +54,14 @@
|
|||
<div class="col-md-6">
|
||||
<div class="card">
|
||||
<div class="card-header">
|
||||
<h4>Notes</h4>
|
||||
<h4>Last notes</h4>
|
||||
</div>
|
||||
<div class="card-body pt-0 pb-0 pr-1 pl-1">
|
||||
{% if last_notes_list %}
|
||||
<table class="table tablesorter table-condensed table-striped" id="notes">
|
||||
<thead>
|
||||
<tr>
|
||||
<th style="width: 8%"></th>
|
||||
<th style="width: 5%"></th>
|
||||
<th style="width: 20%" class='header text-center'>Date</th>
|
||||
<th style="width: 55%" class='header text-center'>Title</th>
|
||||
<th style="width: 30%" class='header text-center'>Coach</th>
|
||||
|
@ -73,12 +74,14 @@
|
|||
<a href="{% url 'note_update' note.id %}">
|
||||
<span class="tim-icons icon-pencil text-warning"></span>
|
||||
</a>
|
||||
{% if not note.status %}
|
||||
<i class="fas fa-exclamation-triangle text-danger"></i>
|
||||
{% endif %}
|
||||
</td>
|
||||
<td class="text-left">
|
||||
<a href="{% url 'note_details' note.id %}">{{ note.date | date:"d-m-Y" }}</a>
|
||||
<td class="text-right">
|
||||
{% if not note.status %}
|
||||
<span class="text-danger">{{ note.date | date:"j-m-Y" }}</span>
|
||||
{% else %}
|
||||
{{ note.date | date:"j-m-Y" }}
|
||||
{% endif %}
|
||||
|
||||
</td>
|
||||
|
||||
<td class="text-left">
|
||||
|
|
|
@ -247,7 +247,7 @@ def gymnast_display_events_and_notes(request, gymnast_id):
|
|||
notes_list = base_queryset
|
||||
notes_list = notes_list.order_by("-created_at")
|
||||
|
||||
last_notes_list = notes_list[:5]
|
||||
last_notes_list = notes_list[:6]
|
||||
latest_published_note = (
|
||||
base_queryset.filter(status=1).order_by("-created_at").first()
|
||||
)
|
||||
|
|
Loading…
Reference in New Issue