diff options
Diffstat (limited to 'app/policies/time_table_policy.rb')
| -rw-r--r-- | app/policies/time_table_policy.rb | 10 | 
1 files changed, 5 insertions, 5 deletions
| diff --git a/app/policies/time_table_policy.rb b/app/policies/time_table_policy.rb index 92d3aef3e..1f5a7a259 100644 --- a/app/policies/time_table_policy.rb +++ b/app/policies/time_table_policy.rb @@ -7,23 +7,23 @@ class TimeTablePolicy < ApplicationPolicy    end    def create? -    !archived? && organisation_match? && user.has_permission?('time_tables.create') +    !archived_or_finalised? && organisation_match? && user.has_permission?('time_tables.create')    end    def destroy? -    !archived? && organisation_match? && user.has_permission?('time_tables.destroy') +    !archived_or_finalised? && organisation_match? && user.has_permission?('time_tables.destroy')    end    def update? -    !archived? && organisation_match? && user.has_permission?('time_tables.update') +    !archived_or_finalised? && organisation_match? && user.has_permission?('time_tables.update')    end    def actualize? -    !archived? && organisation_match? && edit? +    !archived_or_finalised? && organisation_match? && edit?    end    def duplicate? -    !archived? && organisation_match? && create? +    !archived_or_finalised? && organisation_match? && create?    end    def month? | 
