Private
Public Access
1
0

Merge branch 'release/v6.11'

This commit is contained in:
Sander Roosendaal
2018-03-08 08:39:40 +01:00
6 changed files with 28 additions and 5 deletions
+12
View File
@@ -3149,11 +3149,23 @@ def thumbnails_set(r,id,favorites):
rowdata.dropna(axis=1,how='all',inplace=True)
if rowdata.empty:
try:
rowdata = dataprep.getsmallrowdata_db(columns,ids=[id],doclean=False,
workstrokesonly=False)
except:
return [
{'script':"",
'div':"",
'notes':""
}]
if rowdata.empty:
return [
{'script':"",
'div':"",
'notes':""
}]
else:
try:
rowdata.sort_values(by='time',ascending=True,inplace=True)
+2 -2
View File
@@ -101,10 +101,10 @@
<td>
{% if ps.name != '' %}
<a class="small"
href="/rowers/sessions/{{ ps.id }}">{{ ps.name }}</a>
href="/rowers/sessions/{{ ps.id }}/{{ timeperiod }}/rower/{{ rower.id }}">{{ ps.name }}</a>
{% else %}
<a class="small"
href="/rowers/sessions/{{ ps.id }}">Unnamed Session</a>
href="/rowers/sessions/{{ ps.id }}/{{ timeperiod }}/rower/{{ rower.id }}">Unnamed Session</a>
{% endif %}
</td>
<td> {{ ps.get_sessiontype_display }} </td>
+3
View File
@@ -72,6 +72,9 @@
<div id="page" class="grid_12 alpha">
<div class="grid_10 prefix_2 alpha">
<h1>{{ workout.name }}</h1>
{% if workout.user.user != user %}
<h2>{{ workout.user.user.first_name }} {{ workout.user.user.last_name }}
{% endif %}
</div>
<div id="leftpanel" class="grid_2 alpha">
{% block left_panel %}
+5 -1
View File
@@ -70,7 +70,11 @@
<div class="grid_6 alpha">
<table width=100%>
<tr>
{% localtime on %}
{% localtime on %}
{% if workout.user.user != user %}
<th>Rower:</th><td>{{ rower.user.first_name }} {{ rower.user.last_name }}</td>
</tr><tr>
{% endif %}
<th>Date/Time:</th><td>{{ workout.startdatetime|localtime}}</td>
{% endlocaltime %}
</tr><tr>
+4
View File
@@ -8067,6 +8067,8 @@ def workout_flexchart3_view(request,*args,**kwargs):
promember=1
if request.user == row.user.user:
mayedit=1
if checkworkoutuser(request.user,row):
mayedit=1
workouttype = 'ote'
if row.workouttype in ('water','coastal'):
@@ -8796,6 +8798,7 @@ def workout_edit_view(request,id=0,message="",successmessage=""):
'mapscript':mapscript,
'aantalcomments':aantalcomments,
'mapdiv':mapdiv,
'rower':r,
})
else:
@@ -8808,6 +8811,7 @@ def workout_edit_view(request,id=0,message="",successmessage=""):
'mapscript':mapscript,
'aantalcomments':aantalcomments,
'mapdiv':mapdiv,
'rower':r,
})
+1 -1
View File
@@ -94,7 +94,7 @@ MIDDLEWARE_CLASSES = [
'async_messages.middleware.AsyncMiddleware',
'django.middleware.clickjacking.XFrameOptionsMiddleware',
'tz_detect.middleware.TimezoneMiddleware',
'rowers.middleware.GDPRMiddleWare',
# 'rowers.middleware.GDPRMiddleWare',
'rowers.middleware.PowerTimeFitnessMetricMiddleWare',
]