feat(api): add return for all user templates

BREAKING: Template api will return different variables in template
object
This commit is contained in:
Leons Aleksandrovs
2025-07-10 20:36:37 +03:00
parent 9f99f6a4a9
commit e35bf46dac
4 changed files with 36 additions and 16 deletions
+2 -2
View File
@@ -11,7 +11,7 @@ import (
func SetupRoutes() *gin.Engine {
r := gin.Default()
// Guest routes (Register, Login, check auth)
// Guest routes (Register, Login)
r.POST("/register", user.Register)
r.POST("/login", user.Login)
@@ -24,7 +24,7 @@ func SetupRoutes() *gin.Engine {
// Template routes (REST FUCKING GOOOOO)
templates := auth.Group("/templates")
// GET (Gets all templates)
templates.GET("", template.Get)
templates.POST("", template.Create)
// PUT (Edit)
// DELETE (Delete)