mirror of
https://github.com/Sea-Haven-Industries/proposal-system.git
synced 2026-10-01 17:33:14 +00:00
15 lines
374 B
C#
15 lines
374 B
C#
|
|
using FluentValidation;
|
||
|
|
using ProposalSystem.Application.DTOs;
|
||
|
|
|
||
|
|
namespace ProposalSystem.Application.Validators;
|
||
|
|
|
||
|
|
public class CreateCustomerValidator : AbstractValidator<CreateCustomerRequest>
|
||
|
|
{
|
||
|
|
public CreateCustomerValidator()
|
||
|
|
{
|
||
|
|
RuleFor(x => x.Name)
|
||
|
|
.NotEmpty().WithMessage("Customer name is required")
|
||
|
|
.MaximumLength(200);
|
||
|
|
}
|
||
|
|
}
|