{% load seahub_tags group_avatar_tags i18n %}
    {% if group_repos %}
    <table>
        <tr>
            <th width="4%"><!--icon--></th>
            <th width="13%">{% trans "Group" %}</th>
            <th width="4%"><!--icon--></th>
            <th width="20%">{% trans "Name" %}</th>
            <th width="29%">{% trans "Description" %}</th>
            <th width="15%">{% trans "Last Update" %}</th>
            <th width="15%">{% trans "Shared By" %}</th>
        </tr>

        {% for repo in group_repos %}
        <tr>
          {% if repo.show_group_name %}
            <td>{% grp_avatar repo.group.id 20 %}</td>
            <td><a href="{% url 'group_info' repo.group.id %}">{{ repo.group.group_name }}</a></td>
          {% else %}
            <td></td>
            <td></td>
          {% endif %}
            <td>
              {% if repo.encrypted %}
                <img src="{{MEDIA_URL}}img/sync-folder-encrypt-20.png" title="{% trans "Read-Write" %}" alt="{% trans "directory icon" %}" />
              {% else %}
                {% if repo.user_perm == 'rw' %}
                <img src="{{MEDIA_URL}}img/sync-folder-20.png?t=1387267140" title="{% trans "Read-Write" %}" alt="{% trans "directory icon" %}" />
                {% else %}
                <img src="{{MEDIA_URL}}img/folder-no-write-20.png?t=1387267140" title="{% trans "Read-Only" %}" alt="{% trans "directory icon" %}" />
                {% endif %}
              {% endif %}
            </td>
            <td><a href="{% url 'repo' repo.repo_id %}">{{ repo.repo_name }}</a></td>
            <td>{{ repo.repo_desc }}</td>
            {% if repo.last_modified %}
            <td>{{ repo.last_modified|translate_seahub_time }}</td>
            {% else %}
            <td>--</td>
            {% endif %}
            <td>{{ repo.user|email2nickname }}</td>
        </tr>
        {% endfor %}
    </table>
    {% else %}
    <div class="empty-tips">
        <h2 class="alc">{% trans "No library is shared to your groups" %}</h2>
    </div>
    {% endif %}
