summaryrefslogtreecommitdiff
path: root/app/config.py
diff options
context:
space:
mode:
authorKaran Jayachandra <mail@karanjayachandra.com>2025-07-14 14:32:21 +0200
committerKaran Jayachandra <mail@karanjayachandra.com>2025-07-14 14:32:21 +0200
commit82a154260118311b3d2a96a048353b430c6e0161 (patch)
tree0666f0651261dc61e0c20078a825c1d5b610a168 /app/config.py
parent863ab96ca55b9a6a06c1ea499d582b5e264529b5 (diff)
Added the database connection
Diffstat (limited to 'app/config.py')
-rw-r--r--app/config.py5
1 files changed, 3 insertions, 2 deletions
diff --git a/app/config.py b/app/config.py
index d7509a1..2a85d74 100644
--- a/app/config.py
+++ b/app/config.py
@@ -3,12 +3,13 @@ from os.path import abspath, dirname, join
class Config:
- SECRET_KEY = environ.get("SECRET_KEY") or None
- SQLALCHEMY_DATABASE_URI = "sqlite:///" + join(abspath(dirname(__file__)), "app.db")
+ SQLALCHEMY_DATABASE_URI = environ.get("DATABASE_URL") or "sqlite:///" + join(abspath(dirname(__file__)), "app.db")
COURT_COUNT = 12
PLAYERS_PER_COURT = 4
MIN_PLAYER_LEVEL = 1
MAX_PLAYER_LEVEL = 10
+ # Default players as dictionary of first names and primary keys
DEFAULTS = {"---": 1, "RESERVED": 2}
GUEST_COUNT = 4
+ # Guest players as dictionary of first names and play level
GUESTS = {"Beginner": 1, "Novice": 3, "Intermediate": 5} \ No newline at end of file