package tickets

import (
	"gitea.pena/PenaSide/heruvym/internal/tools"
	"github.com/gofiber/fiber/v2"
)

func (t *TicketController) Register(router fiber.Router) {
	router.Post("/create", t.CreateTicket)
	router.Get("/subscribe", tools.SseWrapper(t.GetList))
	router.Get("/ticket", tools.SseWrapper(t.Subscribe))
	router.Post("/send", t.PutMessage)
	router.Post("/getTickets", t.GetTickets)
	router.Post("/getMessages", t.GetMessages)
	router.Post("/pick", t.Pick)
	router.Post("/delegate", t.Delegate)
	router.Post("/vote", t.Vote)
	router.Post("/close", t.CloseTicket)
	router.Post("/shown", t.SetShown)
}

func (t *TicketController) Name() string {
	return ""
}
