quick frontend (app): fixed notifications ids

This commit is contained in:
Goffi 2019-03-20 09:08:47 +01:00
commit e1e00f4d86

View file

@ -897,17 +897,8 @@ class QuickApp(object):
profiles=(profile,)):
widget.onChatState(from_jid, state, profile)
def notify(
self,
type_,
entity=None,
message=None,
subject=None,
callback=None,
cb_args=None,
widget=None,
profile=C.PROF_KEY_NONE,
):
def notify(self, type_, entity=None, message=None, subject=None, callback=None,
cb_args=None, widget=None, profile=C.PROF_KEY_NONE):
"""Trigger an event notification
@param type_(unicode): notifation kind,
@ -937,6 +928,7 @@ class QuickApp(object):
notif_data[widget] = widget
type_notifs.append(notif_data)
self._notifications[self._notif_id] = notif_data
self._notif_id += 1
self.callListeners("notification", entity, notif_data, profile=profile)
def getNotifs(self, entity=None, type_=None, exact_jid=None, profile=C.PROF_KEY_NONE):