From 605f78997ddc53d8b835c31349fed24b7afa9c6d Mon Sep 17 00:00:00 2001 From: Jorai Geertsema Date: Sat, 14 Dec 2024 00:30:50 +0100 Subject: [PATCH] Changed orde roles within policies --- app/policies/activity_policy.rb | 2 +- app/policies/application_policy.rb | 4 ++-- app/policies/price_list_policy.rb | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/app/policies/activity_policy.rb b/app/policies/activity_policy.rb index cf0a970b9..357a78f94 100644 --- a/app/policies/activity_policy.rb +++ b/app/policies/activity_policy.rb @@ -14,7 +14,7 @@ def create? end def update? - user&.treasurer? || user&.main_bartender? || user&.renting_manager? + user&.treasurer? || user&.renting_manager? || user&.main_bartender? end def lock? diff --git a/app/policies/application_policy.rb b/app/policies/application_policy.rb index 542610763..f58bbe0f2 100644 --- a/app/policies/application_policy.rb +++ b/app/policies/application_policy.rb @@ -7,7 +7,7 @@ def initialize(user, record) end def index? - user&.treasurer? || user&.main_bartender? || user&.renting_manager? + user&.treasurer? || user&.renting_manager? || user&.main_bartender? end def show? @@ -31,7 +31,7 @@ def edit? end def destroy? - user&.treasurer? || user&.main_bartender? || user&.renting_manager? + user&.treasurer? || user&.renting_manager? || user&.main_bartender? end def scope diff --git a/app/policies/price_list_policy.rb b/app/policies/price_list_policy.rb index 3433145c7..dca3f943a 100644 --- a/app/policies/price_list_policy.rb +++ b/app/policies/price_list_policy.rb @@ -14,7 +14,7 @@ def index? end def show? - user&.treasurer? || user&.main_bartender? || user&.renting_manager? + user&.treasurer? || user&.renting_manager? || user&.main_bartender? end def create?