{% extends "datagrid/datagrid.html" %}
{% load djblets_deco %}
{% load djblets_utils %}
{% load i18n %}
{% load reviewtags %}
{% load gravatars %}
{% load tz %}
{% block title %}{{viewing_user|user_displayname}}{% endblock %}

{% block content %}
{% box "dashboard" %}
<div id="dashboard-wrapper">
 <table class="datagrid" id="dashboard-navbar">
  <colgroup>
   <col class="summary" />
   <col class="count" />
  </colgroup>
  <tbody>
   <tr>
    <td class="logo">{% gravatar viewing_user 175 %}</td>
   </tr>
   <tr>
    <td><h2 class="nickname">{{viewing_user.username}}</h2></td>
   </tr>
{% if show_profile %}
   <tr>
    <td class="fn">{{viewing_user.first_name}} {{viewing_user.last_name}}</td>
   </tr>
{% if request.user.is_authenticated %}
   <tr>
    <td><a class="email" href="mailto:{{viewing_user.email}}">{{viewing_user.email}}</a></td>
   </tr>
{% endif %}
   <tr>
    <td class="logged-in">Last logged in {% localtime on %}{{viewing_user.last_login|date:"F jS, Y"}}{% endlocaltime %}</td>
   </tr>
   <tr>
    <td class="joined">Joined {% localtime on %}{{viewing_user.date_joined|date:"F jS, Y"}}{% endlocaltime %}</td>
   </tr>
   <tr>
    <td>
     <p><label>{% trans "Groups:" %}</label></p>
{% for group in groups %}
     <a class="group" href="{% url group group %}">{{group}}</a>{% if not forloop.last %}, {% endif %}
{% endfor %}
    </td>
   </tr>
{% endif %}
  </tbody>
 </table>
 <div id="dashboard-main" class="clearfix">
  {{datagrid.render_listview}}
 </div>
</div>
{% endbox %}
{% endblock %}
