Files
bamort/backend/gsmaster/routes.go
T

48 lines
1.6 KiB
Go
Raw Normal View History

2025-07-24 07:39:43 +02:00
package gsmaster
import (
2025-12-30 08:11:33 +01:00
"bamort/user"
2025-07-24 07:39:43 +02:00
"github.com/gin-gonic/gin"
)
func RegisterRoutes(r *gin.RouterGroup) {
maintGrp := r.Group("/maintenance")
2025-12-30 08:11:33 +01:00
maintGrp.Use(user.RequireMaintainer())
{
maintGrp.GET("", GetMasterData)
maintGrp.GET("/skills", GetMDSkills)
2026-01-02 10:21:29 +01:00
maintGrp.GET("/skills-enhanced", GetEnhancedMDSkills) // New enhanced endpoint
2025-12-30 08:11:33 +01:00
maintGrp.GET("/skills/:id", GetMDSkill)
2026-01-02 10:21:29 +01:00
maintGrp.GET("/skills-enhanced/:id", GetEnhancedMDSkill) // New enhanced endpoint
2025-12-30 08:11:33 +01:00
maintGrp.PUT("/skills/:id", UpdateMDSkill)
2026-01-02 10:21:29 +01:00
maintGrp.PUT("/skills-enhanced/:id", UpdateEnhancedMDSkill) // New enhanced endpoint
2025-12-30 08:11:33 +01:00
maintGrp.POST("/skills", AddSkill)
maintGrp.DELETE("/skills/:id", DeleteMDSkill)
2025-07-24 07:39:43 +02:00
2025-12-30 08:11:33 +01:00
maintGrp.GET("/weaponskills", GetMDWeaponSkills)
maintGrp.GET("/weaponskills/:id", GetMDWeaponSkill)
maintGrp.PUT("/weaponskills/:id", UpdateMDWeaponSkill)
maintGrp.POST("/weaponskills", AddWeaponSkill)
maintGrp.DELETE("/weaponskills/:id", DeleteMDWeaponSkill)
2025-07-24 07:39:43 +02:00
2025-12-30 08:11:33 +01:00
maintGrp.GET("/spells", GetMDSpells)
maintGrp.GET("/spells/:id", GetMDSpell)
maintGrp.PUT("/spells/:id", UpdateMDSpell)
maintGrp.POST("/spells", AddSpell)
maintGrp.DELETE("/spells/:id", DeleteMDSpell)
2025-07-24 07:39:43 +02:00
2025-12-30 08:11:33 +01:00
maintGrp.GET("/equipment", GetMDEquipments)
maintGrp.GET("/equipment/:id", GetMDEquipment)
maintGrp.PUT("/equipment/:id", UpdateMDEquipment)
maintGrp.POST("/equipment", AddEquipment)
maintGrp.DELETE("/equipment/:id", DeleteMDEquipment)
2025-07-24 07:39:43 +02:00
2025-12-30 08:11:33 +01:00
maintGrp.GET("/weapons", GetMDWeapons)
maintGrp.GET("/weapons/:id", GetMDWeapon)
maintGrp.PUT("/weapons/:id", UpdateMDWeapon)
maintGrp.POST("/weapons", AddWeapon)
maintGrp.DELETE("/weapons/:id", DeleteMDWeapon)
}
2025-07-24 07:39:43 +02:00
}