package utils

import (
	"jannex/admin-dashboard-backend/modules/structs"

	"git.ex.umbach.dev/Alex/roese-utils/rsvalidator"
)

func ValidatorInit() {
	rsvalidator.Validate.RegisterValidation("numericstring", rsvalidator.ValidateNumericString)

	rsvalidator.Validate.RegisterStructValidationMapRules(generalRules,
		structs.UserLoginRequest{},
		structs.UserSignOutSessionRequest{})

	rsvalidator.Validate.RegisterStructValidationMapRules(groupTaskRules,
		structs.ApiGroupTaskRequest{})

	rsvalidator.Validate.RegisterStructValidationMapRules(equipmentRules,
		structs.EquipmentRequest{},
		structs.GetDocumentationEquipmentRequest{},
		structs.CreateEquipmentDocumentationRequest{},
		structs.EditEquipmentDocumentationRequest{})

	rsvalidator.Validate.RegisterStructValidationMapRules(notificationRules,
		structs.AddNotificationRequest{})
}
