first commit
This commit is contained in:
13
app/routes/display.py
Normal file
13
app/routes/display.py
Normal file
@@ -0,0 +1,13 @@
|
||||
from flask import Blueprint, abort, render_template
|
||||
|
||||
from ..models import Display
|
||||
|
||||
bp = Blueprint("display", __name__, url_prefix="/display")
|
||||
|
||||
|
||||
@bp.get("/<token>")
|
||||
def display_player(token: str):
|
||||
display = Display.query.filter_by(token=token).first()
|
||||
if not display:
|
||||
abort(404)
|
||||
return render_template("display/player.html", display=display)
|
||||
Reference in New Issue
Block a user