From 600b6afff3066d5fc9c4eca659f969322e670a77 Mon Sep 17 00:00:00 2001 From: Karan Jayachandra Date: Tue, 15 Oct 2024 12:07:42 +0200 Subject: Cleaned up the code significantly --- templates/courts.j2 | 5 ++- templates/games.j2 | 19 +++++---- templates/index.j2 | 115 +++++++++++++++++++++++++++++---------------------- templates/player.j2 | 7 +++- templates/players.j2 | 4 +- 5 files changed, 88 insertions(+), 62 deletions(-) (limited to 'templates') diff --git a/templates/courts.j2 b/templates/courts.j2 index 4e3cb3a..5dc64f9 100644 --- a/templates/courts.j2 +++ b/templates/courts.j2 @@ -2,7 +2,10 @@
{% for key, value in courts.items() %}
- +
{% endfor %}
diff --git a/templates/games.j2 b/templates/games.j2 index b070b16..55cabf4 100644 --- a/templates/games.j2 +++ b/templates/games.j2 @@ -1,17 +1,20 @@ + + + - - + + -{% for game in games %} +{% for _, game in games.items() %} - - + {% endfor %} diff --git a/templates/index.j2 b/templates/index.j2 index cfd32b5..3a2118b 100644 --- a/templates/index.j2 +++ b/templates/index.j2 @@ -1,52 +1,67 @@ - - - - 🏸Match Up! - - - - - - -
-
-

🏸The Smashing Fellows

-
-
-
-

Games

-
-
-
-
-
-
-
-
-
-
-
-

Courts

-
-
-
-

Players

-
-
- - - \ No newline at end of file + + + + 🏸Match Up! + + + + + + +
+
+

🏸The Smashing Fellows

+
+
+
+

Games

+
+
+
+ +
+
+
+ +
+
+
+ +
+
+ +
+
+
+
+
+

Courts

+
+
+
+

Players

+
+
+ + + diff --git a/templates/player.j2 b/templates/player.j2 index 5b70df6..68bea2a 100644 --- a/templates/player.j2 +++ b/templates/player.j2 @@ -1 +1,6 @@ - \ No newline at end of file + \ No newline at end of file diff --git a/templates/players.j2 b/templates/players.j2 index 6179dbb..7a13672 100644 --- a/templates/players.j2 +++ b/templates/players.j2 @@ -1,8 +1,8 @@
-{% for player in players %} +{% for id, player in players.items() %}
- +
{% endfor %}
\ No newline at end of file -- cgit v1.3.1
{{ title }}
Court Team 1 Team 2 Team 1 Team 2
{{ game.court.number }}{{ game.team1.player1.name }} - {{ game.team1.player2.name }} - {{ game.team2.player1.name }} - {{ game.team2.player2.name }} + {{ game.court }}{{ game.team1.player1 }} + {{ game.team1.player2 }} + {{ game.team2.player1 }} + {{ game.team2.player2 }}