Add switch user admin tool

This commit is contained in:
rubenwardy
2018-05-13 15:28:27 +01:00
parent 9f33f5fb1b
commit e372bb810d
6 changed files with 130 additions and 56 deletions

View File

@@ -0,0 +1,11 @@
{% extends "base.html" %}
{% block title %}
Admin Tools
{% endblock %}
{% block content %}
<ul>
<a href="{{ url_for('switch_user_page') }}">Sign in as another user</a>
</ul>
{% endblock %}

View File

@@ -0,0 +1,15 @@
{% extends "base.html" %}
{% block title %}
Switch User
{% endblock %}
{% block content %}
{% from "macros/forms.html" import render_field, render_submit_field %}
<form method="POST" action="">
{{ form.hidden_tag() }}
{{ render_field(form.username) }}
{{ render_submit_field(form.submit) }}
</form>
{% endblock %}