Module: PublicActivity::Deactivatable::ClassMethods
- Defined in:
- lib/public_activity/roles/deactivatable.rb
Overview
Provides global methods to disable or enable PublicActivity on a per-class basis.
Instance Method Summary collapse
-
#public_activity_off ⇒ Object
Switches public_activity off for this class.
-
#public_activity_on ⇒ Object
Switches public_activity on for this class.
- #set_public_activity_class_defaults ⇒ Object private
Instance Method Details
#public_activity_off ⇒ Object
Switches public_activity off for this class
27 28 29 |
# File 'lib/public_activity/roles/deactivatable.rb', line 27 def public_activity_off self.public_activity_enabled_for_model = false end |
#public_activity_on ⇒ Object
Switches public_activity on for this class
32 33 34 |
# File 'lib/public_activity/roles/deactivatable.rb', line 32 def public_activity_on self.public_activity_enabled_for_model = true end |
#set_public_activity_class_defaults ⇒ Object
This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.
38 39 40 41 |
# File 'lib/public_activity/roles/deactivatable.rb', line 38 def set_public_activity_class_defaults super self.public_activity_enabled_for_model = true end |