From 47843d9228bef5538f42131dceefa5f1630cae60 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Piotr=20Doma=C5=84ski?= Date: Sun, 2 Apr 2023 12:33:25 +0200 Subject: [PATCH] fix paths --- Readme.md | 9 +++++++++ fooder/view/entry.py | 4 ++-- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/Readme.md b/Readme.md index 57cd84c..36af5ac 100644 --- a/Readme.md +++ b/Readme.md @@ -1 +1,10 @@ # FOODER + +Simple API for food diary application. + +## TODO + +- [ ] Sort meals and entries within meals by date +- [ ] Add refresh tokenization +- [ ] Add access restriction on each endpoint +- [ ] Add tests diff --git a/fooder/view/entry.py b/fooder/view/entry.py index 1ed4649..1056345 100644 --- a/fooder/view/entry.py +++ b/fooder/view/entry.py @@ -15,7 +15,7 @@ async def create_entry( return await contoller.call(data) -@router.put("{entry_id}", response_model=Entry) +@router.put("/{entry_id}", response_model=Entry) async def update_entry( request: Request, entry_id: int, @@ -25,7 +25,7 @@ async def update_entry( return await contoller.call(entry_id, data) -@router.delete("{entry_id}") +@router.delete("/{entry_id}") async def delete_entry( request: Request, entry_id: int,