Self hosted FLOSS fitness/workout, nutrition and weight tracker
Don't show the comment dialog if the user doesn't have enough rights
Roland Geider5d8dd07180c7
diff --git a/exercises/templates/view.html b/exercises/templates/view.htmlindex dee7aa7a7..9eb5cc89b 100644--- a/exercises/templates/view.html+++ b/exercises/templates/view.html@@ -72,6 +72,7 @@ $(document).ready(function() {</tbody></table>+{% if perms.exercises %}<h3>{% trans "Add new comment" %}</h3><form action = "{% url exercises.views.exercise_view exercise.id %}"method = "post"@@ -80,6 +81,7 @@ $(document).ready(function() {{{ comment_form.comment }}<input type="submit" value="{% trans "Save" %}" /></form>+{% endif %}{% endblock %}