Class: Notification

Inherits:
ApplicationRecord show all
Includes:
CommunityRelated
Defined in:
/var/apps/qpixel/app/models/notification.rb

Instance Method Summary collapse

Methods inherited from ApplicationRecord

#attributes_print, fuzzy_search, match_search, #match_search, sanitize_for_search, sanitize_name, sanitize_sql_in, useful_err_msg, with_lax_group_rules

Instance Method Details

#read?Boolean

Is the notification marked as read?

Returns:

  • (Boolean)

    check result



10
11
12
# File '/var/apps/qpixel/app/models/notification.rb', line 10

def read?
  is_read
end

#unread?Boolean

Is the notification not marked as read? The inverse of read?

Returns:

  • (Boolean)

    check result



16
17
18
# File '/var/apps/qpixel/app/models/notification.rb', line 16

def unread?
  !read?
end