Merge tag 'v6.42' into develop
hotfix otw-bests
This commit is contained in:
@@ -721,7 +721,13 @@ def fetchcp(rower,theworkouts,table='cpdata'):
|
|||||||
return pd.Series([]),pd.Series([]),avgpower2
|
return pd.Series([]),pd.Series([]),avgpower2
|
||||||
|
|
||||||
dfgrouped = df.groupby(['workoutid'])
|
dfgrouped = df.groupby(['workoutid'])
|
||||||
avgpower2 = dict(dfgrouped.mean()['power'].astype(int))
|
try:
|
||||||
|
avgpower2 = dict(dfgrouped.mean()['power'].astype(int))
|
||||||
|
except KeyError:
|
||||||
|
avgpower2 = {}
|
||||||
|
for id in theids:
|
||||||
|
avgpower2[id] = 0
|
||||||
|
return pd.Series([]),pd.Series([]),avgpower2
|
||||||
|
|
||||||
cpdf = getcpdata_sql(rower.id,table=table)
|
cpdf = getcpdata_sql(rower.id,table=table)
|
||||||
|
|
||||||
|
|||||||
@@ -198,7 +198,7 @@ class UploadOptionsForm(forms.Form):
|
|||||||
plotchoices = (
|
plotchoices = (
|
||||||
('timeplot','Time Plot'),
|
('timeplot','Time Plot'),
|
||||||
('distanceplot','Distance Plot'),
|
('distanceplot','Distance Plot'),
|
||||||
('pieplot','Pie Chart'),
|
('pieplot','Heart Rate Pie Chart'),
|
||||||
)
|
)
|
||||||
make_plot = forms.BooleanField(initial=False,required=False)
|
make_plot = forms.BooleanField(initial=False,required=False)
|
||||||
plottype = forms.ChoiceField(required=False,
|
plottype = forms.ChoiceField(required=False,
|
||||||
|
|||||||
@@ -13,7 +13,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="grid_2 alpha">
|
<div class="grid_2 alpha">
|
||||||
<p>
|
<p>
|
||||||
<a class="button blue small" href="/rowers/workout/{{ workout.id }}/addpiechart">Add Pie Chart</a>
|
<a class="button blue small" href="/rowers/workout/{{ workout.id }}/addpiechart">Add HR Pie Chart</a>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="grid_2 alpha">
|
<div class="grid_2 alpha">
|
||||||
|
|||||||
@@ -137,7 +137,7 @@
|
|||||||
</div>
|
</div>
|
||||||
<div class="grid_2 omega">
|
<div class="grid_2 omega">
|
||||||
<p>
|
<p>
|
||||||
<a class="button blue small" href="/rowers/workout/{{ workout.id }}/addpiechart">Add Pie Chart</a>
|
<a class="button blue small" href="/rowers/workout/{{ workout.id }}/addpiechart">Add HR Pie Chart</a>
|
||||||
</p>
|
</p>
|
||||||
</div>
|
</div>
|
||||||
<div class="grid_6 alpha">
|
<div class="grid_6 alpha">
|
||||||
|
|||||||
Reference in New Issue
Block a user