Update chrono add and list management
This commit is contained in:
parent
514807204a
commit
c3d34fe174
|
@ -24,7 +24,6 @@
|
|||
</div>
|
||||
</div>
|
||||
<div class="card-body vh-100">
|
||||
<div class="table-responsive">
|
||||
{% if gymnast %}
|
||||
<div class="row">
|
||||
<div class="col-md-6">
|
||||
|
@ -75,12 +74,13 @@
|
|||
</tbody>
|
||||
</table>
|
||||
</div>
|
||||
<div class="col-md-6">
|
||||
<canvas id="chart_chrono" class="chartjs" width="400" height="200"></canvas>
|
||||
<div class="col-md-6 pl-0 pr-0">
|
||||
<canvas id="chart_chrono" class="chartjs" width="100%"></canvas>
|
||||
</div>
|
||||
</div>
|
||||
{% else %}
|
||||
{% if chrono_list %}
|
||||
<div class="table-responsive">
|
||||
<table class="table table-striped tablesorter" id="chrono_table">
|
||||
<thead>
|
||||
<tr>
|
||||
|
@ -128,8 +128,8 @@
|
|||
{% else %}
|
||||
<p class="text-muted">There are no chronos corresponding to your criterias.</p>
|
||||
{% endif %}
|
||||
{% endif %}
|
||||
</div>
|
||||
{% endif %}
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
|
|
@ -476,7 +476,7 @@ def chrono_create_or_update(request, chrono_id=None, gymnast_id=None):
|
|||
)
|
||||
|
||||
return HttpResponseRedirect(
|
||||
reverse("gymnast_details_tab", args=(new_chrono.gymnast.id, "scores"))
|
||||
reverse("chrono_list_for_gymnast", args=(new_chrono.gymnast.id,))
|
||||
)
|
||||
|
||||
return render(request, "chronos/create.html", {"form": form})
|
||||
|
|
Loading…
Reference in New Issue