minecraft_manager/templates/minecraft_manager/player.html

41 lines
1.4 KiB
HTML

{% extends "minecraft_manager/dashboard.html" %}
{% block title %}Players{% endblock %}
{% block section %}
<div id="content" hidden="hidden">
<table id="model-table" class="table table-hover link-table">
<thead>
<tr>
<th>Username</th>
<th>UUID</th>
<th>Banned</th>
<th>Last Seen</th>
</tr>
</thead>
<tbody>
{% for player in players %}
<tr {% if player.uuid in bans %}class="danger"{% endif %}{% if player.uuid not in bans %}class="success"{% endif %} data-id="{{ player.id }}">
<td>{{ player.username }}{% if user.usersettings.search_player_ip is True %}<span hidden="hidden">{{ player.ips }}</span>{% endif %}</td>
<td>{{ player.uuid }}</td>
<td>{% if player.uuid in bans %}True {% else %}False{% endif %}</td>
<td>{{ player.last_seen }}</td>
</tr>
{% endfor %}
</tbody>
</table>
</div>
<script>
$(document).ready(function() {
$("#model-table").DataTable({
'lengthMenu': [ [ 10, 25, 50, 100, -1 ], [ 10, 25, 50, 100, "All" ] ],
'initComplete': function(settings, json) {
$("#content").show();
},
'order': [],
{% if user.usersettings %}
'pageLength': {{ user.usersettings.default_results }},
{% endif %}
});
});
</script>
{% endblock section %}