updated routes for blueprint based app

This commit is contained in:
Simon Pirkelmann 2022-01-27 23:56:48 +01:00
parent 42345273dd
commit b3c585bd27
3 changed files with 13 additions and 13 deletions

View File

@ -27,15 +27,15 @@
{% endfor %} {% endfor %}
<td> <td>
{% if not data['super_admin'] %} {% if not data['super_admin'] %}
<a href="{{ url_for('admin_toggle_active', username=data['username']) }}"><img src="static/stop.png" title="Aktivieren/Deaktivieren" alt="Toggle active"></a> <a href="{{ url_for('door_app.admin_toggle_active', username=data['username']) }}"><img src="static/stop.png" title="Aktivieren/Deaktivieren" alt="Toggle active"></a>
<a href="{{ url_for('delete_admins', username=data['username']) }}"><img src="static/delete.png" title="Löschen" alt="Delete"></a> <a href="{{ url_for('door_app.delete_admins', username=data['username']) }}"><img src="static/delete.png" title="Löschen" alt="Delete"></a>
{% endif %} {% endif %}
{% if data['admin'] %} {% if data['admin'] %}
{% if not data['super_admin'] %} {% if not data['super_admin'] %}
<a href="{{ url_for('demote_admin', username=data['username']) }}"><img src="static/demote.png" title="Admin-Rechte widerrufen" alt="Demote"></a> <a href="{{ url_for('door_app.demote_admin', username=data['username']) }}"><img src="static/demote.png" title="Admin-Rechte widerrufen" alt="Demote"></a>
{% endif %} {% endif %}
{% else %} {% else %}
<a href="{{ url_for('promote_admin', username=data['username']) }}"><img src="static/promote.png" title="Zu Admin machen" alt="Promote"></a> <a href="{{ url_for('door_app.promote_admin', username=data['username']) }}"><img src="static/promote.png" title="Zu Admin machen" alt="Promote"></a>
{% endif %} {% endif %}
</td> </td>
</tr> </tr>
@ -68,14 +68,14 @@
</div> </div>
<div class="p-2 bg-light border"> <div class="p-2 bg-light border">
<h3>Nutzerdaten sichern:</h3> <h3>Nutzerdaten sichern:</h3>
<form action="{{ url_for('backup_user_datastore') }}" method="get"> <form action="{{ url_for('door_app.backup_user_datastore') }}" method="get">
<input type="submit" value="Download"> <input type="submit" value="Download">
</form> </form>
</div> </div>
<div class="p-2 bg-light border"> <div class="p-2 bg-light border">
<h3>Nutzerdaten wiederherstellen:</h3> <h3>Nutzerdaten wiederherstellen:</h3>
<form action="{{ url_for('restore_user_datastore') }}" method=post enctype=multipart/form-data> <form action="{{ url_for('door_app.restore_user_datastore') }}" method=post enctype=multipart/form-data>
<input type=file name=file> <input type=file name=file>
<input type=submit value="Abschicken"> <input type=submit value="Abschicken">
</form> </form>

View File

@ -23,7 +23,7 @@
und diesen zustimmt. und diesen zustimmt.
</li> </li>
<li>Achtung: Der Token funktioniert nicht sofort, sondern muss erst explizit aktiviert werden! <li>Achtung: Der Token funktioniert nicht sofort, sondern muss erst explizit aktiviert werden!
Dazu in der <a href="{{ url_for('list_tokens') }}">Token-Übersicht</a> auf das Bearbeiten-Symbol Dazu in der <a href="{{ url_for('door_app.list_tokens') }}">Token-Übersicht</a> auf das Bearbeiten-Symbol
(<img src="static/edit.png" title="Editieren" alt="Edit">) klicken und den Haken bei "Aktiv?" setzen. (<img src="static/edit.png" title="Editieren" alt="Edit">) klicken und den Haken bei "Aktiv?" setzen.
</li> </li>
<li>Jetzt kann der Token verwendet werden.</li> <li>Jetzt kann der Token verwendet werden.</li>

View File

@ -29,9 +29,9 @@
<td>{{ data[field] if data[field] }}</td> <td>{{ data[field] if data[field] }}</td>
{% endfor %} {% endfor %}
<td> <td>
<a href="{{ url_for('edit_token', token=t) }}"><img src="static/edit.png" title="Editieren" alt="Edit"></a> <a href="{{ url_for('door_app.edit_token', token=t) }}"><img src="static/edit.png" title="Editieren" alt="Edit"></a>
<a href="{{ url_for('deactivate_token', token=t) }}"><img src="static/stop.png" title="Deaktivieren" alt="Deactivate"></a> <a href="{{ url_for('door_app.deactivate_token', token=t) }}"><img src="static/stop.png" title="Deaktivieren" alt="Deactivate"></a>
<a href="{{ url_for('delete_token', token=t) }}"><img src="static/delete.png" title="Löschen" alt="Delete"></a> <a href="{{ url_for('door_app.delete_token', token=t) }}"><img src="static/delete.png" title="Löschen" alt="Delete"></a>
</td> </td>
</tr> </tr>
{% endfor %} {% endfor %}
@ -47,14 +47,14 @@
<td>{{ data[field] if data[field] }}</td> <td>{{ data[field] if data[field] }}</td>
{% endfor %} {% endfor %}
<td> <td>
<a href="{{ url_for('edit_token', token=t) }}"><img src="static/edit.png" title="Editieren" alt="Edit"></a> <a href="{{ url_for('door_app.edit_token', token=t) }}"><img src="static/edit.png" title="Editieren" alt="Edit"></a>
<a href="{{ url_for('delete_token', token=t) }}"><img src="static/delete.png" title="Löschen" alt="Delete"></a> <a href="{{ url_for('door_app.delete_token', token=t) }}"><img src="static/delete.png" title="Löschen" alt="Delete"></a>
</td> </td>
</tr> </tr>
{% endfor %} {% endfor %}
</tbody> </tbody>
</table> </table>
<form action="{{ url_for('backup_tokens') }}" method="get"> <form action="{{ url_for('door_app.backup_tokens') }}" method="get">
<input type="submit" value="Token Daten sichern"> <input type="submit" value="Token Daten sichern">
</form> </form>
{% endblock %} {% endblock %}