Private
Public Access
1
0

solving issue #232 and #234

This commit is contained in:
Sander Roosendaal
2017-11-15 20:05:14 -06:00
parent 7e02f4ab37
commit c3ad8a8500
3 changed files with 17 additions and 3 deletions

View File

@@ -46,14 +46,23 @@
{% for workout in workouts %} {% for workout in workouts %}
<tr> <tr>
<td> <td>
{% if workout|lookup:'source' != 'Web' %}
<a href="/rowers/workout/c2import/{{ workout|lookup:'id' }}/">Import</a></td> <a href="/rowers/workout/c2import/{{ workout|lookup:'id' }}/">Import</a></td>
{% else %}
&nbsp;
{% endif %}
<td>{{ workout|lookup:'starttime' }}</td> <td>{{ workout|lookup:'starttime' }}</td>
<td>{{ workout|lookup:'duration' }}</td> <td>{{ workout|lookup:'duration' }}</td>
<td>{{ workout|lookup:'distance' }}</td> <td>{{ workout|lookup:'distance' }}</td>
<td>{{ workout|lookup:'rowtype' }}</td> <td>{{ workout|lookup:'rowtype' }}</td>
<td>{{ workout|lookup:'source' }}</td> <td>{{ workout|lookup:'source' }}</td>
<td>{{ workout|lookup:'comment' }}</td> <td>{{ workout|lookup:'comment' }}</td>
<td>{{ workout|lookup:'new' }}</td> <td>
{% if workout|lookup:'source' != 'Web' %}
{{ workout|lookup:'new' }}
{% else %}
&nbsp;
{% endif %}</td>
</tr> </tr>
{% endfor %} {% endfor %}

View File

@@ -78,7 +78,12 @@
<div class="grid_4 alpha"> <div class="grid_4 alpha">
&nbsp; &nbsp;
</div> </div>
<div class="grid_4 omega"> <div class="grid_4 omega tooltip">
<span class="tooltiptext">
<p>rPower: Equivalent steady state power for the duration of the workout.</p>
<p>Heart Rate Drift: Comparing heart rate normalized for average power for the first and second half of the workout</p>
<p>rScore: Score based on rPower and workout duration to estimate training effect</p>
</span>
<h2>Other Stats</h2> <h2>Other Stats</h2>
<table width="100%" class="listtable"> <table width="100%" class="listtable">
<thead> <thead>

View File

@@ -8057,7 +8057,7 @@ def workout_getc2workout_all(request,page=1,message=""):
messages.error(request,message) messages.error(request,message)
else: else:
r = getrower(request.user) r = getrower(request.user)
c2ids = [item['id'] for item in res.json()['data']] c2ids = [item['id'] for item in res.json()['data'] if item['source'] != 'Web']
knownc2ids = uniqify([ knownc2ids = uniqify([
w.uploadedtoc2 for w in Workout.objects.filter(user=r) w.uploadedtoc2 for w in Workout.objects.filter(user=r)
]) ])