bugfixes, cleanup
This commit is contained in:
parent
1bf474045a
commit
17c30128ae
82 changed files with 216 additions and 76 deletions
37
lenticular_cloud/template/admin/base.html.j2
Normal file
37
lenticular_cloud/template/admin/base.html.j2
Normal file
|
@ -0,0 +1,37 @@
|
|||
{% extends 'base.html.j2' %}
|
||||
|
||||
|
||||
{% block body %}
|
||||
|
||||
<div class="container-fluid">
|
||||
<div class="row">
|
||||
{% for message in get_flashed_messages() %}
|
||||
<div class="alert alert-warning">
|
||||
<button type="button" class="close" data-dismiss="alert">×</button>
|
||||
{{ message }}
|
||||
</div>
|
||||
{% endfor %}
|
||||
</div>
|
||||
<div class="row">
|
||||
<nav class="col-md-2 d-none d-md-block bg-light sidebar fixed-top">
|
||||
<div class="sidebar-sticky active">
|
||||
<li class="nav-item"><a class="nav-link" href="{{ url_for('admin.users') }}">{{ gettext('users') }}</a></li>
|
||||
<li class="nav-item"><a class="nav-link" href="{{ url_for('admin.registrations') }}">{{ gettext('registrations') }}</a></li>
|
||||
</div>
|
||||
</nav>
|
||||
|
||||
<main class="col-md-9 ml-sm-auto col-lg-10 px-4" role="main">
|
||||
<h1>{% block title %}{% endblock %}</h1>
|
||||
<div class="card">
|
||||
<div class="card-body mt-5 mb-5">
|
||||
<div class="tab-content">
|
||||
{% block content %}{% endblock %}
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
</main>
|
||||
</div>
|
||||
</div>
|
||||
{% endblock %}
|
||||
|
||||
|
2
lenticular_cloud/template/admin/index.html.j2
Normal file
2
lenticular_cloud/template/admin/index.html.j2
Normal file
|
@ -0,0 +1,2 @@
|
|||
|
||||
{% extends 'admin/base.html.j2' %}
|
28
lenticular_cloud/template/admin/registrations.html.j2
Normal file
28
lenticular_cloud/template/admin/registrations.html.j2
Normal file
|
@ -0,0 +1,28 @@
|
|||
{% extends 'admin/base.html.j2' %}
|
||||
|
||||
{% block title %}{{ gettext('registrations') }}{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
|
||||
<table class="table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>username</th>
|
||||
<th>created_at</th>
|
||||
<th>action<th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for user in users %}
|
||||
<tr>
|
||||
<td>{{ user.username }}</td>
|
||||
<td>{{ user.created_at }}</td>
|
||||
<td>
|
||||
<a title="{{ gettext('Reject')}}" href="{{ url_for('.registration_delete', registration_id=user.id) }}" onclick="admin.registration.delete(this.href, '{{ user.username }}'); return false;"><i class="fas fa-ban"></i></a>
|
||||
<a title="{{ gettext('Reject')}}" href="{{ url_for('.registration_accept', registration_id=user.id) }}" onclick="admin.registration.accept(this.href, '{{ user.username }}'); return false;"><i class="fas fa-check"></i></a>
|
||||
</td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
{% endblock%}
|
29
lenticular_cloud/template/admin/users.html.j2
Normal file
29
lenticular_cloud/template/admin/users.html.j2
Normal file
|
@ -0,0 +1,29 @@
|
|||
{% extends 'admin/base.html.j2' %}
|
||||
|
||||
{% block title %}{{ gettext('users') }}{% endblock %}
|
||||
|
||||
{% block content %}
|
||||
|
||||
<table class="table">
|
||||
<thead>
|
||||
<tr>
|
||||
<th>username</th>
|
||||
<th>created_at</th>
|
||||
<th>modified_at</th>
|
||||
<th>last_login</th>
|
||||
<th>action</th>
|
||||
</tr>
|
||||
</thead>
|
||||
<tbody>
|
||||
{% for user in users %}
|
||||
<tr>
|
||||
<td>{{ user.username }}</td>
|
||||
<td>{{ user.created_at }}</td>
|
||||
<td>{{ user.modified_at }}</td>
|
||||
<td>{{ user.last_login }}</td>
|
||||
<td> </td>
|
||||
</tr>
|
||||
{% endfor %}
|
||||
</tbody>
|
||||
</table>
|
||||
{% endblock%}
|
Loading…
Add table
Add a link
Reference in a new issue