a bit more logic navigating the training planning functions
This commit is contained in:
@@ -35,7 +35,7 @@
|
||||
Please correct the error{{ form.errors|pluralize }} below.
|
||||
</p>
|
||||
{% endif %}
|
||||
|
||||
|
||||
<table>
|
||||
{{ form.as_table }}
|
||||
</table>
|
||||
@@ -89,9 +89,9 @@
|
||||
<td>
|
||||
<a class="small" href="/rowers/sessions/{{ ps.id }}/deleteconfirm/">Delete</a>
|
||||
</td>
|
||||
<td>
|
||||
<a class="small" href="/rowers/sessions/{{ ps.id }}/maketemplate/">Save</a>
|
||||
</td>
|
||||
<td>
|
||||
<a class="small" href="/rowers/sessions/{{ ps.id }}/maketemplate/">Save</a>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
@@ -144,7 +144,7 @@
|
||||
|
||||
$("td #id_course").hide();
|
||||
$("th label[for='id_course']").hide();
|
||||
|
||||
|
||||
$("td #id_sessionmode").change(function() {
|
||||
|
||||
if (this.value == 'TRIMP') {
|
||||
@@ -192,7 +192,7 @@
|
||||
$("th label[for='id_course']").hide();
|
||||
$("td #id_course").hide();
|
||||
}
|
||||
|
||||
|
||||
if (this.value == 'challenge') {
|
||||
$("td #id_criterium").prop("value","minimum");
|
||||
$('#id_guidance').html("<p>For Challenges, the default criterium is 'At Least'</p>");
|
||||
@@ -228,7 +228,7 @@
|
||||
|
||||
}
|
||||
|
||||
);
|
||||
);
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -23,14 +23,14 @@
|
||||
</p>
|
||||
</li>
|
||||
<li class="grid_2">
|
||||
<p><a href="/rowers/sessions/?startdate={{ timeperiod|previousperiodstart }}&enddate={{ timeperiod|previousperiodend}}">Back by
|
||||
<p><a href="/rowers/sessions/coach/?startdate={{ timeperiod|previousperiodstart }}&enddate={{ timeperiod|previousperiodend}}">Back by
|
||||
{{ timeperiod|timedeltadays }} days</a>
|
||||
</p>
|
||||
<p><a href="/rowers/sessions/?startdate={{ timeperiod|nextperiodstart }}&enddate={{ timeperiod|nextperiodend}}">Forward by
|
||||
<p><a href="/rowers/sessions/coach/?startdate={{ timeperiod|nextperiodstart }}&enddate={{ timeperiod|nextperiodend}}">Forward by
|
||||
{{ timeperiod|timedeltadays }} days</a>
|
||||
</p>
|
||||
</li>
|
||||
<li class="grid_4">
|
||||
<li class="grid_4">
|
||||
|
||||
|
||||
<table width="90%" class="listtable">
|
||||
@@ -80,7 +80,7 @@
|
||||
</td>
|
||||
{% endfor %}
|
||||
</tr>
|
||||
{% endfor %}
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
<p>
|
||||
@@ -129,7 +129,7 @@
|
||||
{% else %}
|
||||
<td>
|
||||
<a href={% url rower.defaultlandingpage id=workout.id|encode %}>No Name
|
||||
</a></td>
|
||||
</a></td>
|
||||
{% endif %}
|
||||
|
||||
{% else %}
|
||||
@@ -144,7 +144,7 @@
|
||||
<td> {{ workout.duration |durationprint:"%H:%M:%S.%f" }} </td>
|
||||
<td> {{ workout.averagehr }} </td>
|
||||
<td> {{ workout.maxhr }} </td>
|
||||
</tr>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
@@ -153,7 +153,7 @@
|
||||
|
||||
{% endif %}
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
</ul>
|
||||
|
||||
@@ -19,10 +19,10 @@
|
||||
</p>
|
||||
</li>
|
||||
<li class="grid_2">
|
||||
<p><a href="/rowers/sessions/?startdate={{ timeperiod|previousperiodstart }}&enddate={{ timeperiod|previousperiodend}}">Back by
|
||||
<p><a href="/rowers/sessions/teamcreate/?startdate={{ timeperiod|previousperiodstart }}&enddate={{ timeperiod|previousperiodend}}">Back by
|
||||
{{ timeperiod|timedeltadays }} days</a>
|
||||
</p>
|
||||
<p><a href="/rowers/sessions/?startdate={{ timeperiod|nextperiodstart }}&enddate={{ timeperiod|nextperiodend}}">Forward by
|
||||
<p><a href="/rowers/sessions/teamcreate/?startdate={{ timeperiod|nextperiodstart }}&enddate={{ timeperiod|nextperiodend}}">Forward by
|
||||
{{ timeperiod|timedeltadays }} days</a>
|
||||
</p>
|
||||
</li>
|
||||
@@ -34,21 +34,21 @@
|
||||
Please correct the error{{ form.errors|pluralize }} below.
|
||||
</p>
|
||||
{% endif %}
|
||||
|
||||
|
||||
<ul class="main-content">
|
||||
<li class="grid_2">
|
||||
{% csrf_token %}
|
||||
|
||||
|
||||
<h1>New Team Session</h1>
|
||||
<table>
|
||||
{{ teamform.as_table }}
|
||||
{{ teamform.as_table }}
|
||||
</table>
|
||||
<table>
|
||||
{{ form.as_table }}
|
||||
</table>
|
||||
<input class="button green" type="submit" value="Save">
|
||||
<div id="id_guidance" class="padded">
|
||||
|
||||
|
||||
</div>
|
||||
</li>
|
||||
{% if plannedsessions %}
|
||||
@@ -90,15 +90,18 @@
|
||||
<td>
|
||||
<a class="small" href="/rowers/sessions/{{ ps.id }}/clone/">Clone</a>
|
||||
</td>
|
||||
|
||||
|
||||
<td>
|
||||
<a class="small" href="/rowers/sessions/{{ ps.id }}/deleteconfirm/">Delete</a>
|
||||
</td>
|
||||
<td>
|
||||
<a class="small" href="/rowers/sessions/{{ ps.id }}/maketemplate/">Save</a>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</p>
|
||||
</p>
|
||||
</li>
|
||||
{% endif %}
|
||||
<li class="grid_2">
|
||||
@@ -150,7 +153,7 @@
|
||||
$(document).ready(function(){
|
||||
$("td #id_course").hide();
|
||||
$("th label[for='id_course']").hide();
|
||||
|
||||
|
||||
$("td #id_sessionmode").change(function() {
|
||||
|
||||
if (this.value == 'TRIMP') {
|
||||
@@ -165,16 +168,16 @@
|
||||
$("td #id_sessionunit").prop("value","min");
|
||||
$('#id_guidance').html("<p>Time: Set value to minutes</p>");
|
||||
}
|
||||
|
||||
|
||||
if (this.value == 'rScore') {
|
||||
$("td #id_sessionunit").prop("value","None");
|
||||
$('#id_guidance').html("<p>rScore has no unit</p>");
|
||||
}
|
||||
|
||||
|
||||
});
|
||||
|
||||
|
||||
$("td #id_sessiontype").change(function() {
|
||||
|
||||
|
||||
if (this.value == 'session') {
|
||||
$("td #id_criterium").prop("value","none");
|
||||
$('#id_guidance').html("<p>For Training Sessions, the default criterium is 'Approximately'</p>");
|
||||
@@ -205,18 +208,18 @@
|
||||
$("td #id_criterium").prop("value","minimum");
|
||||
$('#id_guidance').html("<p>For Challenges, the default criterium is 'At Least'</p>");
|
||||
}
|
||||
|
||||
|
||||
if (this.value == 'cycletarget') {
|
||||
$("td #id_criterium").prop("value","none");
|
||||
$('#id_guidance').html("<p>For Cycle Targets, the default criterium is 'Approximately'</p>");
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
);
|
||||
|
||||
|
||||
$("td #id_sessionunit").change(function() {
|
||||
|
||||
|
||||
if (this.value == 'm') {
|
||||
$("td #id_sessionmode").prop("value","distance");
|
||||
$('#id_guidance').html("<p>Mode was set to distance</p>");
|
||||
@@ -233,13 +236,13 @@
|
||||
$("td #id_sessionmode").prop("value","time");
|
||||
$('#id_guidance').html("<p>Mode was set to time</p>");
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
);
|
||||
|
||||
|
||||
|
||||
|
||||
);
|
||||
|
||||
|
||||
|
||||
});
|
||||
|
||||
</script>
|
||||
|
||||
@@ -19,10 +19,10 @@
|
||||
</p>
|
||||
</li>
|
||||
<li class="grid_2">
|
||||
<p><a href="/rowers/sessions/?startdate={{ timeperiod|previousperiodstart }}&enddate={{ timeperiod|previousperiodend}}">Back by
|
||||
<p><a href="/rowers/sessions/coach/?startdate={{ timeperiod|previousperiodstart }}&enddate={{ timeperiod|previousperiodend}}">Back by
|
||||
{{ timeperiod|timedeltadays }} days</a>
|
||||
</p>
|
||||
<p><a href="/rowers/sessions/?startdate={{ timeperiod|nextperiodstart }}&enddate={{ timeperiod|nextperiodend}}">Forward by
|
||||
<p><a href="/rowers/sessions/coach/?startdate={{ timeperiod|nextperiodstart }}&enddate={{ timeperiod|nextperiodend}}">Forward by
|
||||
{{ timeperiod|timedeltadays }} days</a>
|
||||
</p>
|
||||
</li>
|
||||
@@ -41,10 +41,10 @@
|
||||
<p>
|
||||
Selecting a team assigns this session to all members of the team.
|
||||
Unselecting a team does not remove rowers
|
||||
who are already assigned to this session. Use the Rowers selection for that.
|
||||
who are already assigned to this session. Use the Rowers selection for that.
|
||||
</p><p>
|
||||
<table>
|
||||
{{ teamform.as_table }}
|
||||
{{ teamform.as_table }}
|
||||
</table></p>
|
||||
</li>
|
||||
<li class="grid_2">
|
||||
@@ -112,15 +112,18 @@
|
||||
<td>
|
||||
<a class="small" href="/rowers/sessions/{{ ps.id }}/clone">Clone</a>
|
||||
</td>
|
||||
|
||||
|
||||
<td>
|
||||
<a class="small" href="/rowers/sessions/{{ ps.id }}/deleteconfirm">Delete</a>
|
||||
</td>
|
||||
<td>
|
||||
<a class="small" href="/rowers/sessions/{{ ps.id }}/maketemplate/">Save</a>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
</p>
|
||||
</p>
|
||||
{% endif %}
|
||||
|
||||
</li>
|
||||
@@ -134,7 +137,7 @@
|
||||
$(document).ready(function(){
|
||||
|
||||
var o = $("td #id_sessiontype").find(":selected").val();
|
||||
|
||||
|
||||
if (o != 'coursetest') {
|
||||
$("td #id_course").hide();
|
||||
$("th label[for='id_course']").hide();
|
||||
@@ -230,7 +233,7 @@
|
||||
|
||||
}
|
||||
|
||||
);
|
||||
);
|
||||
|
||||
|
||||
|
||||
|
||||
@@ -19,6 +19,9 @@
|
||||
|
||||
{% endif %}
|
||||
</p>
|
||||
<p>
|
||||
Login <em>{{ rower.user }}</em>
|
||||
</p>
|
||||
{% if userform.errors %}
|
||||
<p style="color: red;">
|
||||
Please correct the error{{ form.errors|pluralize }} below.
|
||||
@@ -26,7 +29,7 @@
|
||||
{% endif %}
|
||||
{% if accountform.errors %}
|
||||
<p style="color: red;">
|
||||
|
||||
|
||||
</p>
|
||||
{% endif %}
|
||||
<form enctype="multipart/form-data" action="" method="post">
|
||||
|
||||
Reference in New Issue
Block a user