aboutsummaryrefslogtreecommitdiffstats
path: root/app/policies/network_policy.rb
blob: 9b871d2b539a0a7f4fa048052d8bfc79925e5d69 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
class NetworkPolicy < ApplicationPolicy
  class Scope < Scope
    def resolve
      scope
    end
  end
  def create?
    user.has_permission?('networks.create')
  end

  def destroy?
    user.has_permission?('networks.destroy')
  end

  def update?
    user.has_permission?('networks.update')
  end
end