This commit is contained in:
Edward Betts 2023-09-25 18:26:40 +01:00
parent 295e833621
commit 6c16b87fff

3
confarchive/view.py Executable file → Normal file
View file

@ -1,4 +1,4 @@
#!/usr/bin/python3
"""Flask views."""
import os
@ -17,6 +17,7 @@ database.init_app(app)
@app.route("/person/<int:person_id>", methods=["GET", "POST"])
def person(person_id: int) -> str | Response:
"""Person page."""
item = model.Person.query.get(person_id)
if flask.request.method == "POST" and check_admin_mode():
qid = flask.request.form["wikidata_qid"] or None