phase2: add modular apps, auth scaffolding, and base template routing

This commit is contained in:
Alfredo Di Stasio
2026-03-10 10:27:40 +01:00
parent 35686bdb66
commit f47ffe6c15
63 changed files with 594 additions and 24 deletions

View File

@ -1,8 +1,11 @@
from django.urls import path
from .views import health, home
from .views import DashboardView, HomeView, health
app_name = "core"
urlpatterns = [
path("", home, name="home"),
path("", HomeView.as_view(), name="home"),
path("dashboard/", DashboardView.as_view(), name="dashboard"),
path("health/", health, name="health"),
]

View File

@ -1,9 +1,14 @@
from django.contrib.auth.mixins import LoginRequiredMixin
from django.views.generic import TemplateView
from django.http import JsonResponse
from django.shortcuts import render
def home(request):
return render(request, "home.html")
class HomeView(TemplateView):
template_name = "core/home.html"
class DashboardView(LoginRequiredMixin, TemplateView):
template_name = "core/dashboard.html"
def health(request):