From a06a7e8f23bfd64565da4e4141f186180e84a104 Mon Sep 17 00:00:00 2001 From: Dylan Bolger Date: Mon, 17 Aug 2026 16:58:04 -0500 Subject: initial push of photoblog --- app/routers/web.py | 9 +++++++++ 1 file changed, 9 insertions(+) create mode 100644 app/routers/web.py (limited to 'app/routers/web.py') diff --git a/app/routers/web.py b/app/routers/web.py new file mode 100644 index 0000000..e97bc42 --- /dev/null +++ b/app/routers/web.py @@ -0,0 +1,9 @@ +from fastapi import APIRouter, Request + +router = APIRouter(prefix="/photos") + +@router.get("/") +async def main_page(request: Request): + images = request.app.state.image_service.get_all_images() + return request.app.state.templates.TemplateResponse( + request=request, name="index.html", context={"images": images}) \ No newline at end of file -- cgit v1.2.3