Added mark_as_unread in model

This commit is contained in:
Jesper Håkansson 2014-04-03 15:50:06 +02:00
parent 5ac698d973
commit 0cb60574bb

View file

@ -150,6 +150,11 @@ class Notification(models.Model):
if self.unread:
self.unread = False
self.save()
def mark_as_unread(self):
if self.unread:
self.unread = True
self.save()
EXTRA_DATA = False
if getattr(settings, 'NOTIFY_USE_JSONFIELD', False):