Files
Govor/Govor.Core/Requests/LoginRequest.cs
T
2025-06-24 21:43:35 +07:00

16 lines
464 B
C#

using System.ComponentModel.DataAnnotations;
using Govor.Core.Infrastructure.Validators;
namespace Govor.Core.Requests;
public class LoginRequest
{
[Required]
[StringLength(UserValidator.MAX_LENGHT_OF_NAME,
MinimumLength = UserValidator.MIN_LENGHT_OF_NAME,
ErrorMessage = "Username must be between 4 and 50 characters.")]
public string Name { get; init; }
[Required]
[MinLength(8)]
public string Password { get; init; }
}