admin register page

This commit is contained in:
DaanoGames
2025-04-15 10:54:26 +02:00
parent cae4bc7b5b
commit e186f735a7
2 changed files with 28 additions and 13 deletions

View File

@@ -0,0 +1,24 @@
{% extends 'base_template.html' %}
{% block title %}
Register
{% endblock %}
{% block content %}
{% if feedback %}
<p>{{feedback}}</p>
{% endif %}
<form class="bg-body-tertiary" method="POST">
{{ form.hidden_tag() }}
<div>
{{ form.username.label }} <br> {{ form.username() }}
</div>
<div>
{{ form.password.label }} <br> {{ form.password() }}
</div>
<div class="submit">
{{ form.submit() }}
</div>
</form>
{% endblock %}

View File

@@ -30,20 +30,11 @@
<li class="nav-item">
<a class="nav-link" href="#">Info</a>
</li>
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" href="#" role="button" data-bs-toggle="dropdown"
aria-expanded="false">
Dropdown
</a>
<ul class="dropdown-menu">
<li><a class="dropdown-item" href="#">Action</a></li>
<li><a class="dropdown-item" href="#">Another action</a></li>
<li>
<hr class="dropdown-divider">
</li>
<li><a class="dropdown-item" href="#">Something else here</a></li>
</ul>
{% if current_user.is_admin %}
<li class="nav-item">
<a class="nav-link" href="{{url_for('dash.admin')}}">Add user</a>
</li>
{% endif %}
</ul>
{% if current_user.is_authenticated %}
<a class="btn btn-outline-info" data-bs-theme="dark" href="{{url_for('auth.logout')}}">Logout</a>