2019-09-14 18:36:23 -04:00
|
|
|
<!DOCTYPE html>
|
|
|
|
<html lang="en">
|
|
|
|
<head>
|
|
|
|
<title>Buckler</title>
|
2019-09-20 19:24:12 -04:00
|
|
|
<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">
|
2019-09-14 18:36:23 -04:00
|
|
|
</head>
|
|
|
|
<body>
|
2019-09-20 19:24:12 -04:00
|
|
|
<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>
|
2019-09-14 18:36:23 -04:00
|
|
|
</body>
|
|
|
|
</html>
|