pyfedi/app/templates/community/community_find_moderator.html

51 lines
2.4 KiB
HTML
Raw Normal View History

{% if theme() and file_exists('app/templates/themes/' + theme() + '/base.html') %}
{% extends 'themes/' + theme() + '/base.html' %}
{% else %}
{% extends "base.html" %}
2024-12-10 03:16:52 -08:00
{% endif %}
{% from 'bootstrap/form.html' import render_form %}
{% block app_content %}
<div class="row">
<div class="col col-login mx-auto">
<div class="card mt-5">
<div class="card-body p-6">
<div class="card-title">{{ _('Add moderator to %(community)s', community=community.display_name()) }}</div>
{{ render_form(form) }}
</div>
</div>
</div>
</div>
{% if potential_moderators != None %}
<div class="row">
<div class="col mx-auto">
<div class="card mt-5">
<div class="card-body p-6">
{% if potential_moderators -%}
<div class="card-title">{{ _('Found some people:') }}</div>
<table class="table table-striped">
{% for user in potential_moderators -%}
<tr>
<td class="align-middle">{{ render_username(user) }}</td>
<td class="text-right">
{% if community_membership(user, community) != SUBSCRIPTION_MODERATOR %}
<a class="btn btn-primary" href="{{ url_for('community.community_add_moderator', community_id=community.id, user_id=user.id) }}">{{ _('Add') }}</a>
{% else %}
{{ _('Already a moderator') }}
{% endif %}
</td>
</tr>
{% endfor -%}
</table>
</div>
{% else -%}
<div class="card-title">{{ _('No people found') }}</div>
<p>{{ _('Only local accounts can be added as moderators.') }}</p>
{% endif -%}
</div>
</div>
</div>
</div>
{% endif %}
{% endblock %}