add uid to notifications listing items
This commit is contained in:
parent
c64f067d6e
commit
e27f4000f7
1 changed files with 4 additions and 3 deletions
|
@ -67,14 +67,14 @@ class NotificationsListing(ConceptView):
|
||||||
if s is None:
|
if s is None:
|
||||||
sender = dict(label=u'???', url=u'')
|
sender = dict(label=u'???', url=u'')
|
||||||
else:
|
else:
|
||||||
sender = dict(label=s.title,
|
sender = dict(label=s.title,
|
||||||
url=self.nodeView.getUrlForTarget(baseObject(s)))
|
url=self.nodeView.getUrlForTarget(baseObject(s)))
|
||||||
obj = util.getObjectForUid(track.taskId)
|
obj = util.getObjectForUid(track.taskId)
|
||||||
if obj is None:
|
if obj is None:
|
||||||
continue
|
continue
|
||||||
ov = self.nodeView.getViewForTarget(obj)
|
ov = self.nodeView.getViewForTarget(obj)
|
||||||
url = '%s?form.action=notification_read&track=%s' % (
|
url = '%s?form.action=notification_read&track=%s' % (
|
||||||
self.nodeView.getUrlForTarget(obj),
|
self.nodeView.getUrlForTarget(obj),
|
||||||
util.getUidForObject(track))
|
util.getUidForObject(track))
|
||||||
object = dict(label=ov.title, url=url)
|
object = dict(label=ov.title, url=url)
|
||||||
read_ts = self.formatTimeStamp(data.get('read_ts'))
|
read_ts = self.formatTimeStamp(data.get('read_ts'))
|
||||||
|
@ -82,7 +82,8 @@ class NotificationsListing(ConceptView):
|
||||||
sender=sender,
|
sender=sender,
|
||||||
object=object,
|
object=object,
|
||||||
text=data.get('text') or u'',
|
text=data.get('text') or u'',
|
||||||
read_ts=read_ts)
|
read_ts=read_ts,
|
||||||
|
uid=util.getUidForObject(track))
|
||||||
result.append(item)
|
result.append(item)
|
||||||
return result
|
return result
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue