template details
This commit is contained in:
@@ -366,7 +366,7 @@
|
|||||||
|
|
||||||
<p>Click on the cycle to fold out its contents.</p>
|
<p>Click on the cycle to fold out its contents.</p>
|
||||||
|
|
||||||
<p>Click on the plan cycles to edit their names, start and end dates.
|
<p>
|
||||||
The gray "filler"
|
The gray "filler"
|
||||||
cycles are generated, adjusted and deleted automatically to
|
cycles are generated, adjusted and deleted automatically to
|
||||||
ensure the entire plan
|
ensure the entire plan
|
||||||
|
|||||||
@@ -72,9 +72,17 @@
|
|||||||
<td> {{ plan.enddate }}</td>
|
<td> {{ plan.enddate }}</td>
|
||||||
<td><a href="/rowers/plan/{{ plan.id }}">{{ plan.name }}</a></td>
|
<td><a href="/rowers/plan/{{ plan.id }}">{{ plan.name }}</a></td>
|
||||||
<td> {% if plan.status %} active {% else %} inactive {% endif %}</td>
|
<td> {% if plan.status %} active {% else %} inactive {% endif %}</td>
|
||||||
<td> <a href="/rowers/editplan/{{ plan.id }}">Edit</a></td>
|
<td>
|
||||||
|
{% if request.user == plan.manager %}
|
||||||
|
<a href="/rowers/editplan/{{ plan.id }}">Edit</a>
|
||||||
|
{% endif %}
|
||||||
|
</td>
|
||||||
<td> <a href="/rowers/plan/{{ plan.id }}">Plan</a></td>
|
<td> <a href="/rowers/plan/{{ plan.id }}">Plan</a></td>
|
||||||
<td> <a href="/rowers/deleteplan/{{ plan.id }}">Delete</a></td>
|
<td>
|
||||||
|
{% if request.user == plan.manager %}
|
||||||
|
<a href="/rowers/deleteplan/{{ plan.id }}">Delete</a>
|
||||||
|
{% endif %}
|
||||||
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
{% endfor %}
|
{% endfor %}
|
||||||
</tbody>
|
</tbody>
|
||||||
|
|||||||
@@ -16588,7 +16588,8 @@ def rower_trainingplan_view(request,
|
|||||||
r = getrequestrower(request,userid=userid)
|
r = getrequestrower(request,userid=userid)
|
||||||
|
|
||||||
if not checkaccessuser(request.user,plan.manager):
|
if not checkaccessuser(request.user,plan.manager):
|
||||||
raise PermissionDenied("Access denied")
|
if request.user.rower not in plan.rowers.all():
|
||||||
|
raise PermissionDenied("Access denied")
|
||||||
|
|
||||||
createmacrofillers(plan)
|
createmacrofillers(plan)
|
||||||
macrocycles = TrainingMacroCycle.objects.filter(
|
macrocycles = TrainingMacroCycle.objects.filter(
|
||||||
|
|||||||
Reference in New Issue
Block a user