Module: CanCan::ControllerAdditions
- Defined in:
- lib/cancan_edit/controller_additions.rb
Class Method Summary collapse
Instance Method Summary collapse
Class Method Details
.included(base) ⇒ Object
3 4 5 |
# File 'lib/cancan_edit/controller_additions.rb', line 3 def self.included(base) base.helper_method :can_edit?, :cannot_edit? end |
Instance Method Details
#can_edit?(*args) ⇒ Boolean
7 8 9 |
# File 'lib/cancan_edit/controller_additions.rb', line 7 def can_edit?(*args) current_ability.can_edit?(*args) end |
#cannot_edit?(*args) ⇒ Boolean
11 12 13 |
# File 'lib/cancan_edit/controller_additions.rb', line 11 def cannot_edit?(*args) current_ability.cannot_edit?(*args) end |