From a7e67ef8f4ce501bebc3978983c3d2edfc81bd21 Mon Sep 17 00:00:00 2001 From: Win-10 Date: Fri, 3 Oct 2025 23:51:46 +0300 Subject: [PATCH] =?UTF-8?q?=D0=B4=D0=BE=D0=B1=D0=B0=D0=B2=D0=B8=D0=BB=20?= =?UTF-8?q?=D0=BA=D0=BE=D0=BC=D0=BC=D0=B5=D0=BD=D1=82=D0=B0=D1=80=D0=B8?= =?UTF-8?q?=D0=B8=20=D0=BA=20=D1=8D=D0=BD=D0=B4=D0=BF=D0=BE=D0=B8=D0=BD?= =?UTF-8?q?=D1=82=D0=B0=D0=BC?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- main.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/main.go b/main.go index 08811b5..7ce296f 100644 --- a/main.go +++ b/main.go @@ -23,9 +23,9 @@ func main() { todoService := service.New(todoRepository) todoHandler := handler.New(todoService) - r.POST("/users", todoHandler.CreateUser) - r.POST("/users/:id/pages", todoHandler.CreatePage) - r.POST("/pages/:id/tasks", todoHandler.CreateTask) + r.POST("/users", todoHandler.CreateUser) // Создание юзера + r.POST("/users/:id/pages", todoHandler.CreatePage) // Создание страницы по userID + r.POST("/pages/:id/tasks", todoHandler.CreateTask) // Создание задачи по pageID r.GET("/users/:id", todoHandler.GetUserByID) // Получение пользователя по ID r.GET("/users/:id/pages", todoHandler.GetPagesByUserID) // Страницы пользователя r.GET("/pages/:id", todoHandler.GetPageByID) // Страница по ID