Private
Public Access
1
0

easy changing to athlete's workouts list for coaches

This commit is contained in:
Sander Roosendaal
2018-01-24 14:55:18 +01:00
parent 865d7837f9
commit 3e0b98fab8
4 changed files with 59 additions and 7 deletions

View File

@@ -50,7 +50,6 @@
<div class="grid_12">
Select start and end date for a date range:
<div class="grid_4 alpha">
{% if team %}
@@ -64,9 +63,25 @@
</table>
{% csrf_token %}
</div>
<div class="grid_2 suffix_6 alpha">
<div class="grid_2">
<input name='daterange' class="button green" type="submit" value="Submit"> </form>
</div>
{% if user.is_authenticated and user|is_manager %}
<div class="grid_2 omega dropdown">
<button class="grid_2 alpha button green small dropbtn">
Change Rower
</button>
<div class="dropdown-content">
{% for member in user|team_members %}
<a class="button green small" href="/rowers/u/{{ member.id }}/list-workouts/{{ startdate|date:"Y-m-d" }}/{{ enddate|date:"Y-m-d" }}">{{ member.first_name }} {{ member.last_name }}</a>
{% endfor %}
</div>
</div>
{% else %}
&nbsp;
{% endif %}
</div>
@@ -77,11 +92,12 @@
{% endif %}
<div class="grid_12">
<div id="workouts_table" class="grid_8 alpha">
{% if team %}
<h3>{{ team.name }} Team Workouts</h3>
{% else %}
<h3>My Workouts</h3>
<h3>Workouts of {{ rower.user.first_name }} {{ rower.user.last_name }}</h3>
{% endif %}
{% if workouts %}
@@ -154,7 +170,10 @@
</td>
{% else %}
<td colspan="2">
{{ workout.user.user.first_name }} {{ workout.user.user.last_name }}
<a class="small" href="/rowers/{{ workout.user.id }}/list-workouts">
{{ workout.user.user.first_name }}
{{ workout.user.user.last_name }}
</a>
</td>
{% endif %}
<td> <a class="small" href="/rowers/workout/{{ workout.id }}/flexchart">Flex</a> </td>