Add page/route to display selected topset from a workout for a person

This commit is contained in:
Peter Stockings
2022-07-16 16:47:28 +10:00
parent 50231f5462
commit 83841d6369
4 changed files with 91 additions and 20 deletions

5
app.py
View File

@@ -44,6 +44,11 @@ def show_workout_for_person(person_id, workout_id):
return render_template('workout.html', person_id=person_id, workout_id=workout_id)
@app.route("/person/<int:person_id>/workout/<int:workout_id>/topset/<int:topset_id>")
def show_topset_from_workout_for_person(person_id, workout_id, topset_id):
return render_template('topset.html', person_id=person_id, workout_id=workout_id, topset_id=topset_id)
@app.teardown_appcontext
def close_connection(exception):
db = getattr(g, '_database', None)