Skip to content

Commit

Permalink
Initial rendering of seenBy
Browse files Browse the repository at this point in the history
  • Loading branch information
dcramer committed Apr 15, 2014
1 parent 5b6aa08 commit fe08a13
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
6 changes: 3 additions & 3 deletions src/sentry/api/endpoints/group_details.py
Expand Up @@ -34,13 +34,13 @@ def _get_activity(self, request, group, num=7):
return activity[:num]

def _get_seen_by(self, request, group):
seen_by = sorted(filter(lambda ls: ls[0] != request.user and ls[0].email, [
seen_by = sorted([
(gs.user, gs.last_seen)
for gs in GroupSeen.objects.filter(
group=group
).select_related('user')
]), key=lambda ls: ls[1], reverse=True)
return seen_by
], key=lambda ls: ls[1], reverse=True)
return [s[0] for s in seen_by]

def get(self, request, group_id):
group = Group.objects.get(
Expand Down
6 changes: 3 additions & 3 deletions src/sentry/static/sentry/app/templates/group-details.html
Expand Up @@ -18,9 +18,9 @@ <h3>{{selectedGroup.title}}</h3>
<div class="seen-by">
<ul>
<li>Seen by</li>
<li><a href="#"><img src="http://github.com/ckj.png" /></a></li>
<li><a href="#"><img src="http://github.com/dcramer.png" /></a></li>
<li><a href="#"><img src="http://github.com/mattrobenolt.png" /></a></li>
<li ng-repeat="user in selectedGroup.seenBy">
<a href="#"><img src="{{user.avatarUrl}}" /></a>
</ul>
</ul>
</div>
<div class="group-actions">
Expand Down

0 comments on commit fe08a13

Please sign in to comment.