1
0
Fork 0
mirror of https://codeberg.org/Mo8it/AdvLabDB.git synced 2024-09-17 18:31:15 +00:00

Added users table

This commit is contained in:
Mo 2021-03-19 21:40:40 +01:00
parent 7a5a852cd7
commit 34145c8522
2 changed files with 12 additions and 1 deletions

View file

@ -105,5 +105,13 @@ def groups():
@app.route("/users")
def users():
headerAndDataList = [["Email", "row.email"],
["Is admin", "row.is_admin"],
["Assistant", "row.assistant"]]
table = makeTable(headerAndDataList=headerAndDataList,
rows=User.query.all())
page = "users"
return render_template(page + ".html", navbarItems=navbarItems(page))
return render_template(page + ".html", navbarItems=navbarItems(page),
table=table)

View file

@ -1,3 +1,6 @@
{% extends "layout.html" %}
{% block content %}
{{table|safe}}
{% endblock content %}