Module: Permissify::Controller

Includes:
Common
Defined in:
lib/permissify/controller.rb

Instance Method Summary collapse

Methods included from Common

#allowed_to?, #createable?, #deleteable?, #log_permissions, #permissible?, #subscribed_to?, #updateable?, #viewable?

Instance Method Details

#permission(action, category) ⇒ Object

interface used by Permissfy::Common.allowed_to?



6
7
8
9
# File 'lib/permissify/controller.rb', line 6

def permission(action, category) # interface used by Permissfy::Common.allowed_to?
  @permissions ||= construct_permissions # TODO : get lazier?
  permissible?(@permissions, action, category)
end