|
@ -79,7 +79,6 @@ class CoreNotifier(Notification): |
|
|
q.update({Notif.read: True}) |
|
|
q.update({Notif.read: True}) |
|
|
|
|
|
|
|
|
db.commit() |
|
|
db.commit() |
|
|
#db.close() |
|
|
|
|
|
|
|
|
|
|
|
return jsonified({ |
|
|
return jsonified({ |
|
|
'success': True |
|
|
'success': True |
|
@ -107,7 +106,6 @@ class CoreNotifier(Notification): |
|
|
ndict['type'] = 'notification' |
|
|
ndict['type'] = 'notification' |
|
|
notifications.append(ndict) |
|
|
notifications.append(ndict) |
|
|
|
|
|
|
|
|
#db.close() |
|
|
|
|
|
return jsonified({ |
|
|
return jsonified({ |
|
|
'success': True, |
|
|
'success': True, |
|
|
'empty': len(notifications) == 0, |
|
|
'empty': len(notifications) == 0, |
|
@ -133,7 +131,6 @@ class CoreNotifier(Notification): |
|
|
|
|
|
|
|
|
self.frontend(type = listener, data = data) |
|
|
self.frontend(type = listener, data = data) |
|
|
|
|
|
|
|
|
#db.close() |
|
|
|
|
|
return True |
|
|
return True |
|
|
|
|
|
|
|
|
def frontend(self, type = 'notification', data = {}, message = None): |
|
|
def frontend(self, type = 'notification', data = {}, message = None): |
|
|