51 lines
1.2 KiB
HTML
51 lines
1.2 KiB
HTML
<!DOCTYPE html>
|
|
<html lang="en">
|
|
<head>
|
|
<title>Buckler</title>
|
|
<script>
|
|
var users_perms = {{ users_json|safe }};
|
|
</script>
|
|
<script type="text/javascript" src="/static/buckler.js"></script>
|
|
<link rel="stylesheet" type="text/css" href="/static/buckler.css">
|
|
</head>
|
|
<body>
|
|
<header>
|
|
<object id="logo" data="/static/buckler_icon.svg"></object>
|
|
<h1>Buckler</h1>
|
|
</header>
|
|
<main>
|
|
<div>
|
|
Available sites
|
|
<ul id="avail_sites">
|
|
{% for site in avail_sites %}
|
|
<li><a href="{{ site['url'] }}">{{ site['name'] }}</a></li>
|
|
{% endfor %}
|
|
</ul>
|
|
</div>
|
|
{% if request['session']['admin'] %}
|
|
<table id="users">
|
|
<thead>
|
|
<tr>
|
|
<th>User</th>
|
|
{% for app in apps %}
|
|
<th>{{ app }}</th>
|
|
{% endfor %}
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
{% for username, values in users.items() %}
|
|
<tr>
|
|
<td>{{ username }}</td>
|
|
{% for value in values %}
|
|
<td><input type="checkbox" onchange="perm_change(this.parentElement.parentElement)"{% if value %} checked{% endif %}></td>
|
|
{% endfor %}
|
|
<td><input type="submit"></td>
|
|
</tr>
|
|
{% endfor %}
|
|
</tbody>
|
|
</table>
|
|
{% endif %}
|
|
</main>
|
|
</body>
|
|
</html>
|