admin_user.html (2363B) download
1{% extends "layout.html" %}
2{% block content %}
3<div class="media">
4 <img class="rounded-circle account-img" src="{{ image_file }}">
5 <div class="media-body">
6 <h2 class="account-heading">{{ user.username }}</h2>
7 <p class="text-secondary">{{ user.email }}</p>
8 </div>
9</div>
10<form method="POST" action="">
11 {{ form.hidden_tag() }}
12 <fieldset class="form-group">
13 <legend class="border-bottom mb-4">Rechten bewerken!</legend>
14 <div class="form-group">
15 {{ form.type.label(class="form-control-label") }}
16 {% if form.type.errors %}
17 {{ form.type(class="form-control form-control-lg is-invalid") }}
18 <div class="invalid-feedback">
19 {% for error in form.type.errors %}
20 <span>{{ error }}</span>
21 {% endfor %}
22 </div>
23 {% else %}
24 {{ form.type(class="form-control form-control-lg") }}
25 {% endif %}
26 </div>
27 </fieldset>
28 <div class="form-group">
29 <button type="button" class="btn btn-danger btn-sm m-1" data-toggle="modal"
30 data-target="#deleteModal">Verwijderen</button>
31 <a class="btn btn-danger btn-sm m-1" href="{{ url_for('reset_user', user_id=user.id) }}">Wachtwoord
32 terugzetten</a>
33 <br><br>
34 {{ form.submit(class="btn btn-outline-info") }}
35 </div>
36</form>
37<!-- Modal -->
38<div class="modal fade" id="deleteModal" tabindex="-1" role="dialog" aria-labelledby="deleteModalLabel"
39 aria-hidden="true">
40 <div class="modal-dialog" role="document">
41 <div class="modal-content">
42 <div class="modal-header">
43 <h5 class="modal-title" id="deleteModalLabel">Profiel verwijderen?</h5>
44 <button type="button" class="close" data-dismiss="modal" aria-label="Close">
45 <span aria-hidden="true">×</span>
46 </button>
47 </div>
48 <div class="modal-footer">
49 <button type="button" class="btn btn-secondary" data-dismiss="modal">Sluiten</button>
50 <form action="{{ url_for('delete_user', user_id=user.id) }}" method="POST">
51 <input class="btn btn-danger" type="submit" value="Delete">
52 </form>
53 </div>
54 </div>
55 </div>
56</div>
57{% endblock content %}