From 5db50bc27113b5de4703ec86bba9e9d426d81171 Mon Sep 17 00:00:00 2001 From: Gregory Ballantine Date: Tue, 18 Nov 2025 15:30:33 -0500 Subject: [PATCH] Started project with initial Flask layout --- app.py | 3 +++ app/__init__.py | 9 +++++++++ app/controllers/top.py | 7 +++++++ app/templates/layout.jinja | 15 +++++++++++++++ app/templates/top/dashboard.jinja | 7 +++++++ 5 files changed, 41 insertions(+) create mode 100644 app.py create mode 100644 app/__init__.py create mode 100644 app/controllers/top.py create mode 100644 app/templates/layout.jinja create mode 100644 app/templates/top/dashboard.jinja diff --git a/app.py b/app.py new file mode 100644 index 0000000..a409859 --- /dev/null +++ b/app.py @@ -0,0 +1,3 @@ +import .app + +app.create_app() diff --git a/app/__init__.py b/app/__init__.py new file mode 100644 index 0000000..90d1155 --- /dev/null +++ b/app/__init__.py @@ -0,0 +1,9 @@ +from flask import Flask +from .controllers.top import top_bp + +def create_app(): + app = Flask(__name__) + + app.register_blueprint(top_bp) + + return app diff --git a/app/controllers/top.py b/app/controllers/top.py new file mode 100644 index 0000000..e6ac6f6 --- /dev/null +++ b/app/controllers/top.py @@ -0,0 +1,7 @@ +from flask import Blueprint, render_template + +top_bp = Blueprint('top', __name__, url_prefix='/') + +@top_bp.route('/') +def profile(): + return render_template('top/dashboard.jinja') diff --git a/app/templates/layout.jinja b/app/templates/layout.jinja new file mode 100644 index 0000000..d66b788 --- /dev/null +++ b/app/templates/layout.jinja @@ -0,0 +1,15 @@ + + + + {% block title %}{% endblock %} | Muspah + + +
+

Muspah

+
+ +
+ {% block content %}{% endblock %} +
+ + diff --git a/app/templates/top/dashboard.jinja b/app/templates/top/dashboard.jinja new file mode 100644 index 0000000..b303e72 --- /dev/null +++ b/app/templates/top/dashboard.jinja @@ -0,0 +1,7 @@ +{% extends 'layout.jinja' %} + +{% block title %}Dashboard{% endblock %} + +{% block content %} +

Welcome to the Muspah dashboard!

+{% endblock %}