diff --git a/app/__init__.py b/app/__init__.py index 23e0920..47625cc 100644 --- a/app/__init__.py +++ b/app/__init__.py @@ -14,5 +14,7 @@ login.login_view = 'login' login.login_message = "Veuillez vous authentifier avant de continuer." from app import models # IDK why this is here, but it works -from app.routes import index, login, search, account, admin, users # To load routes at initialization +from app.routes import index, search, users # To load routes at initialization +from app.routes.account import login, account +from app.routes.admin import index, groups, account from app.utils import pluralize # To use pluralize into the templates diff --git a/app/routes/account.py b/app/routes/account/account.py similarity index 100% rename from app/routes/account.py rename to app/routes/account/account.py diff --git a/app/routes/login.py b/app/routes/account/login.py similarity index 97% rename from app/routes/login.py rename to app/routes/account/login.py index 900dece..b594f9a 100644 --- a/app/routes/login.py +++ b/app/routes/account/login.py @@ -5,8 +5,6 @@ from app.forms.login import LoginForm from app.models.users import Member from app.utils.render import render -# from app.routes.index import index - @app.route('/login', methods=['GET', 'POST']) def login(): diff --git a/app/routes/admin/edit-account.py b/app/routes/admin/account.py similarity index 100% rename from app/routes/admin/edit-account.py rename to app/routes/admin/account.py