module Strongbolt::Bolted::InstanceMethods
Public Instance Methods
accessible?(action, attrs = :any)
click to toggle source
Asks permission to performa an operation on the current instance
# File lib/strongbolt/bolted.rb, line 82 def accessible?(action, attrs = :any) unbolted? || Grant::User.current_user.can?(action, self, attrs) end
strongbolt_owner_id()
click to toggle source
Returns the owner id according to what's
# File lib/strongbolt/bolted.rb, line 89 def strongbolt_owner_id raise ModelNotOwned unless self.class.owned? send self.class.owner_attribute end