Class: UserNotification::Notification
- Inherits:
-
Object
- Object
- UserNotification::Notification
- Defined in:
- lib/user_notification/activity.rb,
lib/user_notification/models/notification.rb
Overview
Main model, stores all information about what happened, who caused it, when and anything else.
Direct Known Subclasses
Instance Method Summary collapse
Instance Method Details
#mark_as_read ⇒ Object
4 5 6 |
# File 'lib/user_notification/models/notification.rb', line 4 def mark_as_read self.read = true end |
#mark_as_read! ⇒ Object
8 9 10 |
# File 'lib/user_notification/models/notification.rb', line 8 def mark_as_read! self.update_attribute(:read, true) end |