Private
Public Access
1
0

team stats page

This commit is contained in:
Sander Roosendaal
2017-05-15 20:22:15 +02:00
parent 1530cdaa61
commit a3e61ec215
9 changed files with 143 additions and 63 deletions

View File

@@ -33,55 +33,59 @@
</div>
<div id="workouts_table" class="grid_8 alpha">
{% if team %}
<div class="grid_8 alpha">
{% include "teambuttons.html" with teamid=team.id %}
</div>
<h3>{{ team.name }} Team Workouts</h3>
{% else %}
<h3>My Workouts</h3>
{% endif %}
{% if team %}
<div class="grid_12 alpha">
{% include "teambuttons.html" with teamid=team.id team=team %}
</div>
{% endif %}
{% if workouts %}
<table width="100%" class="listtable shortpadded">
<thead>
<tr>
<th style="width:80px"> Date</th>
<th> Time</th>
<th> Name</th>
<th> Type</th>
<th> Distance </th>
<th> Duration </th>
<th> Avg HR </th>
<th> Max HR </th>
{% if not team %}
<th> &nbsp;</th>
<th> &nbsp;</th>
{% else %}
<th colspan="2">
Owner
</th>
{% endif %}
</tr>
<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>
{% endif %}
{% if workouts %}
<table width="100%" class="listtable shortpadded">
<thead>
<tr>
<th style="width:80px"> Date</th>
<th> Time</th>
<th> Name</th>
<th> Type</th>
<th> Distance </th>
<th> Duration </th>
<th> Avg HR </th>
<th> Max HR </th>
{% if not team %}
<th> &nbsp;</th>
<th> &nbsp;</th>
{% else %}
<th colspan="2">
Owner
</th>
{% endif %}
</tr>
</thead>
<tbody>
{% for workout in workouts %}
<tr>
<td> {{ workout.date |truncatechars:15}} </td>
<td> {{ workout.starttime }} </td>
<td>
{% if workout.user.user == user or user == team.manager %}
{% if workout.name != '' %}
<a href="/rowers/workout/{{ workout.id }}/edit">{{ workout.name }}</a> </td>
{% else %}
<a href="/rowers/workout/{{ workout.id }}/edit">No Name</a> </td>
<tbody>
{% for workout in workouts %}
<tr>
<td> {{ workout.date |truncatechars:15}} </td>
<td> {{ workout.starttime }} </td>
<td>
{% if workout.user.user == user or user == team.manager %}
{% if workout.name != '' %}
<a href="/rowers/workout/{{ workout.id }}/edit">{{ workout.name }}</a> </td>
{% else %}
<a href="/rowers/workout/{{ workout.id }}/edit">No Name</a> </td>
{% endif %}
{% else %}
{% if workout.name != '' %}
<a href="/rowers/workout/{{ workout.id }}/">{{ workout.name }}</a> </td>
{% else %}
<a href="/rowers/workout/{{ workout.id }}/">No Name</a> </td>
{% if workout.name != '' %}
<a href="/rowers/workout/{{ workout.id }}/">{{ workout.name }}</a> </td>
{% else %}
<a href="/rowers/workout/{{ workout.id }}/">No Name</a> </td>
{% endif %}
{% endif %}
<td> {{ workout.workouttype }} </td>
@@ -114,6 +118,7 @@
{% endif %}
</div>
<div class="grid_4 omega">
{% if team %}
<div class="grid_4" id="teambuttons">
@@ -152,7 +157,7 @@
</div>
</div>
</div>
</div>
<div class="grid_5 alpha">