using FluentValidation;

using Monitoring.Common.Validators;

namespace Monitoring.Features.FaultManagement.GetFaultList;

public class GetFaultListValidator : AbstractValidator<GetFaultListRequest>
{
	public GetFaultListValidator()
	{
		_ = RuleFor(x => x).SetValidator(new TableStateValidator());

		_ = RuleFor(x => x.AssetId).NotEmpty().When(x => x.AssetId.HasValue);
	}
}