summaryrefslogtreecommitdiff
path: root/src/match_up/routes.py
diff options
context:
space:
mode:
authorKaran Jayachandra <mail@karanjayachandra.com>2024-12-02 19:33:48 +0100
committerKaran Jayachandra <mail@karanjayachandra.com>2024-12-02 19:33:48 +0100
commitbeea33bc183837a3feceaf1b5127c2e21e16fc36 (patch)
treeed0d9b5f4e3ad600f8d498227323576800983608 /src/match_up/routes.py
parent6ebbee2016b0232573ad1d322b4d4ca6287b3599 (diff)
Added team based games
Diffstat (limited to 'src/match_up/routes.py')
-rw-r--r--src/match_up/routes.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/match_up/routes.py b/src/match_up/routes.py
index 8ae18ce..f9cd2fa 100644
--- a/src/match_up/routes.py
+++ b/src/match_up/routes.py
@@ -17,8 +17,9 @@ def get_controls():
@_app.route("/propose", methods=["POST"])
def get_random_games():
- levels = int(request.form["type"].split()[0])
- return render_template("games.j2", games=_rg.propose(levels), title="Proposal")
+ levels = int(request.form["levels"].split()[0])
+ team_practice = request.form["team"] == "Teams"
+ return render_template("games.j2", games=_rg.propose(levels, team_practice), title="Proposal")
@_app.route("/confirm", methods=["POST"])