has "Make Ranking" on left panel workflow page
This commit is contained in:
@@ -527,6 +527,7 @@ def fetchcp(rower,theworkouts,table='cpdata'):
|
|||||||
theids = [int(w.id) for w in theworkouts]
|
theids = [int(w.id) for w in theworkouts]
|
||||||
columns = ['power','workoutid','time']
|
columns = ['power','workoutid','time']
|
||||||
df = getsmallrowdata_db(columns,ids=theids)
|
df = getsmallrowdata_db(columns,ids=theids)
|
||||||
|
df.dropna(inplace=True,axis=0)
|
||||||
if df.empty:
|
if df.empty:
|
||||||
avgpower2 = {}
|
avgpower2 = {}
|
||||||
for id in theids:
|
for id in theids:
|
||||||
|
|||||||
6
rowers/templates/panel_ranking.html
Normal file
6
rowers/templates/panel_ranking.html
Normal file
@@ -0,0 +1,6 @@
|
|||||||
|
<div class="grid_2 alpha">
|
||||||
|
<p>
|
||||||
|
<a class="button gray small" href="/rowers/workout/{{ workout.id }}/updatecp">
|
||||||
|
Make Ranking Piece</a>
|
||||||
|
</p>
|
||||||
|
</div>
|
||||||
@@ -79,6 +79,10 @@
|
|||||||
<td>Four intervals of 6, 5, 3 and 3 minutes length, 3 minutes rest</td>
|
<td>Four intervals of 6, 5, 3 and 3 minutes length, 3 minutes rest</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
|
<td>8x500m/3:30min </td>
|
||||||
|
<td>8 times 500m with 3 minutes 30 seconds rest</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
<td>4x(500m+500m)/5min</td><td>4 times 1km, but each km is reported as two 500m intervals without rest</td>
|
<td>4x(500m+500m)/5min</td><td>4 times 1km, but each km is reported as two 500m intervals without rest</td>
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
|
|||||||
@@ -45,6 +45,7 @@ workflowleftpanel = (
|
|||||||
('panel_editstream.html','Edit Stream Data'),
|
('panel_editstream.html','Edit Stream Data'),
|
||||||
('panel_otwpower.html','Run OTW Power Calculations'),
|
('panel_otwpower.html','Run OTW Power Calculations'),
|
||||||
('panel_mapview.html','Map'),
|
('panel_mapview.html','Map'),
|
||||||
|
('panel_ranking.html','Ranking View'),
|
||||||
)
|
)
|
||||||
|
|
||||||
defaultleft = [
|
defaultleft = [
|
||||||
|
|||||||
@@ -3252,7 +3252,10 @@ def workout_update_cp_view(request,id=0):
|
|||||||
|
|
||||||
dataprep.runcpupdate(r)
|
dataprep.runcpupdate(r)
|
||||||
|
|
||||||
url = reverse(otwrankings_view)
|
if row.workouttype in ('water','coastal'):
|
||||||
|
url = reverse(otwrankings_view)
|
||||||
|
else:
|
||||||
|
url = reverse(oterankings_view)
|
||||||
|
|
||||||
return HttpResponseRedirect(url)
|
return HttpResponseRedirect(url)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user