WIP: Groups support

This commit is contained in:
2018-07-26 10:44:47 +02:00
parent eaf71d4ce6
commit 74530347e2
8 changed files with 411 additions and 1 deletions

View File

@@ -0,0 +1,33 @@
{% extends 'base.html' %}
{% from '_macros.html' import profile_link %}
{% block content %}
<h2 class="ui header">
{% if group.visibility == 'secret' %}
[secret]
{% elif group.visibility == 'closed' %}
[closed]
{% elif group.visibility == 'public' %}
[public]
{% endif %}
{{group.display_name }}
<small>{{ group.fqn }}</small>
</h2>
{% if not current_user.profile or not current_user.profile.is_member_of(group) %}
{% if group.visibility == 'public' %}
Join
{% else %}
Request membership
{% endif %}
{% else %}
Invitation form
{% endif %}<br>
{% if group.details_visible_to(current_user.profile) %}
<h2>{% trans %}Members{% endtrans %}</h2>
{% for member in group.members %}
{{ profile_link(member) }}
{% endfor %}
{% else %}
The details of this grop are not visible to you.
{% endif %}
{% endblock content %}