show-group.html 3.32 KB
Newer Older
1 2
{% extends "base.html" %}
{% load i18n %}
3
{% load staticfiles %}
4
{% get_current_language as LANGUAGE_CODE %}
5 6 7 8 9 10

{% block title %}
{% blocktrans with name=group.name %}Details of {{name}}{% endblocktrans %}
- {{block.super}}
{% endblock %}

11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28
{% block content %}
<div class="boxes">
    {% include "box/person/box.html" %}
    <div class="contentblock" id="group-owners">
        <h2>{% trans "Owners of" %}: {{group.name}}</h2>
        <ul class="entry-list">
            {% for owner in owners %}
            <li class="entry small-row">
                <div class="summary">
                    <div class="name">
                        {% if not owner.user %}
                        {{owner.code}}
                        {% else %}
                        {{owner}} ({{owner.code}})
                        {% endif %}
                    </div>
                    <!--<div class="actions">
                        <a href="#" class="remove" data-gid="{{group.id}}" data-neptun="{{owner.code}}">
29
                            <img src="{% static "icons/minus-circle.png" %}" alt="{% trans 'Remove' %}" />
30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61
                        </a>
                    </div>-->
                    <div class="clear"></div>
                </div>
                <div class="details">
                    <div class="container">
                        {% if not owner.user %}
                        {% trans "This user never logged in, no data available" %}
                        {% else %}
                        <ul>
                            <li>
                                {% trans "Name" %}<span class="value">{{owner}}</span>
                            </li>
                            <li>
                                {% trans "NEPTUN" %}<span class="value">{{owner.code}}</span>
                            </li>
                            <li>
                                E-mail:<span class="value"><a href="mailto:{{owner.user.email}}">{{owner.user.email}}</a></span>
                            </li>
                        </ul>
                        {% endif %}
                    </div>
                </div>
            </li>
            {% endfor %}
            <li class="entry small-row">
                <div class="summary" id="new-owner" data-gid="{{group.id}}">
                    <div class="name">{% trans "Add owner" %}</div>
                    <div class="clear"></div>
                </div>
                <div class="details" id="new-owner-form">
                    <div class="container">
62
                        <input type="text" placeholder="{% trans "Owner name/NEPTUN" %}" data-url="{% url school.views.group_ajax_owner_autocomplete %}"/>
63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86
                        <div id="new-owner-autocomplete"></div>
                    </div>
                </div>
            </li>
        </ul>
    </div>
</div>
<div class="boxes">
    {% if noshare %}
        <div class="tooltip" style="position:absolute">
            <div class="container">
                <p>
                    {% trans "This group has no shared templates." %}
                </p>
                <p>
                    {% trans "Share one, and the group members can start their own virtual machine." %}
                </p>
                <div class="tail"></div>
            </div>
        </div>
    {% endif %}
    {% include "box/template/box.html" %}
</div>
{% endblock %}