Private
Public Access
1
0

coaches can edit video analysis

This commit is contained in:
Sander Roosendaal
2019-12-16 17:25:24 +01:00
parent 9a3c8b95ba
commit b20381be9d
2 changed files with 5 additions and 2 deletions

View File

@@ -306,7 +306,7 @@ function copyText() {
}
</script>
</li>
{% if user.is_authenticated and user == workout.user.user %}
{% if user.is_authenticated and workout|may_edit:request %}
<li class="grid_4">
<input type="checkbox" name="lock" id="lock" value="Lock">Lock Data and Video
</li>
@@ -322,7 +322,7 @@ function copyText() {
<li class="grid_2">
{% if form and user.is_authenticated and user == workout.user.user %}
{% if form and user.is_authenticated and workout|may_edit:request %}
<table>
{{ form.as_table }}

View File

@@ -172,6 +172,9 @@ def workout_video_create_view(request,id=0):
else:
mode = 'erg'
mayedit = checkworkoutuser(request.user,w) and isprorower(request.user.rower)
# get video ID and offset
if request.method == 'POST':
form = VideoAnalysisCreateForm(request.POST)