Class: CanCan::InheritedResource
- Inherits:
-
ControllerResource
- Object
- ControllerResource
- CanCan::InheritedResource
- Defined in:
- lib/atreides.rb
Overview
For use with Inherited Resources
Instance Method Summary collapse
- #collection_instance ⇒ Object
-
#collection_instance=(instance) ⇒ Object
def resource_instance @controller.send(:resource) if load_instance? end.
-
#load_collection ⇒ Object
defer this directly to Inherited Resources.
- #resource_instance=(instance) ⇒ Object
Instance Method Details
#collection_instance ⇒ Object
34 35 36 |
# File 'lib/atreides.rb', line 34 def collection_instance @controller.send :collection end |
#collection_instance=(instance) ⇒ Object
def resource_instance
@controller.send(:resource) if load_instance?
end
31 32 |
# File 'lib/atreides.rb', line 31 def collection_instance=(instance) end |
#load_collection ⇒ Object
defer this directly to Inherited Resources
20 21 22 |
# File 'lib/atreides.rb', line 20 def load_collection @controller.send(:collection) end |
#resource_instance=(instance) ⇒ Object
24 25 |
# File 'lib/atreides.rb', line 24 def resource_instance=(instance) end |