Merge tag 'v3.4.0' into hometown-dev
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
class DeliveryPolicy < ApplicationPolicy
|
||||
def clear_delivery_errors?
|
||||
admin?
|
||||
end
|
||||
|
||||
def restart_delivery?
|
||||
admin?
|
||||
end
|
||||
|
||||
def stop_delivery?
|
||||
admin?
|
||||
end
|
||||
end
|
||||
@@ -0,0 +1,15 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
class FollowRecommendationPolicy < ApplicationPolicy
|
||||
def show?
|
||||
staff?
|
||||
end
|
||||
|
||||
def suppress?
|
||||
staff?
|
||||
end
|
||||
|
||||
def unsuppress?
|
||||
staff?
|
||||
end
|
||||
end
|
||||
@@ -0,0 +1,19 @@
|
||||
# frozen_string_literal: true
|
||||
|
||||
class RulePolicy < ApplicationPolicy
|
||||
def index?
|
||||
staff?
|
||||
end
|
||||
|
||||
def create?
|
||||
admin?
|
||||
end
|
||||
|
||||
def update?
|
||||
admin?
|
||||
end
|
||||
|
||||
def destroy?
|
||||
admin?
|
||||
end
|
||||
end
|
||||
Reference in New Issue
Block a user