cds-web/routes/groupe.go

22 lines
655 B
Go
Raw Normal View History

2022-10-21 03:12:22 +02:00
package routes
import (
"cds/controllers"
"github.com/gofiber/fiber/v2"
)
func GroupRoute(route fiber.Router) {
route.Get("/:id", controllers.GetInfos)
route.Get("/:id/events", controllers.GetEvents)
route.Put("/create", controllers.CreateGroup)
2022-10-29 23:05:16 +02:00
route.Put("/:id/join", controllers.JoinGroup)
route.Put("/:id/leave", controllers.LeaveGroupe)
2022-10-21 03:12:22 +02:00
route.Put("/switch", controllers.ChangeLeader)
route.Put("/events/plan", controllers.CreateEvent)
route.Put("/events/change", controllers.ChangeEvent)
route.Put("/end", controllers.EndGroup)
route.Delete("/cancel", controllers.DeleteGroup)
route.Delete("/events/cancel", controllers.DeleteEvent)
}