using FluentValidation;

namespace Monitoring.Features.ServiceOrganization.UpdateServiceOrganization;

public class UpdateServiceOrganizationValidator
	: AbstractValidator<UpdateServiceOrganizationRequest>
{
	public UpdateServiceOrganizationValidator()
	{

		RuleFor(x => x.Name)
			.NotEmpty()
			.MaximumLength(100);

		RuleFor(x => x.Timestamp)
			.NotNull()
			.Must(ts => ts.Length > 0);
	}
}