Adjust teacher permissions:

* Hide non-public exercises and proxy exercises
* Hide average working time value on statistic page
* Add hint about filter to submission page for teachers
* Hide display name from feedback page
This commit is contained in:
Sebastian Serth
2020-09-07 18:31:45 +02:00
parent 8b087e897c
commit afafe0c218
8 changed files with 12 additions and 6 deletions

View File

@@ -4,7 +4,7 @@ class ProxyExercisePolicy < AdminOrAuthorPolicy
end
def show?
admin? || teacher?
admin? || teacher_in_study_group? || teacher? && @record.public? || author?
end
[:clone?, :destroy?, :edit?, :update?].each do |action|