Merge remote-tracking branch 'origin/develop' into develop
# Conflicts: # Knots/obj/Debug/net8.0/Knots.AssemblyInfo.cs # Knots/obj/Debug/net8.0/Knots.AssemblyInfoInputs.cache # Knots/obj/rider.project.model.nuget.info
This commit is contained in:
@@ -1,6 +1,23 @@
|
||||
using FastEndpoints;
|
||||
using FluentValidation;
|
||||
using Knots.DTO.Message;
|
||||
|
||||
namespace Knots.Validators.Message;
|
||||
|
||||
public class CreateMessageDtoValidator
|
||||
public class CreateMessageDtoValidator : Validator<CreateMessageDto>
|
||||
{
|
||||
|
||||
public CreateMessageDtoValidator()
|
||||
{
|
||||
RuleFor(x => x.Contenu)
|
||||
.NotEmpty()
|
||||
.WithMessage("Le message ne peux pas être vide")
|
||||
.MaximumLength(1000)
|
||||
.WithMessage("Le message ne doit pas faire plus de 1000 caractères");
|
||||
|
||||
|
||||
RuleFor(x => x.Date)
|
||||
.NotEmpty()
|
||||
.WithMessage("La date ne peut pas être vide");
|
||||
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,17 @@
|
||||
using FastEndpoints;
|
||||
using FluentValidation;
|
||||
using Knots.DTO.Role;
|
||||
|
||||
namespace Knots.Validators.Role;
|
||||
|
||||
public class CreateRoleDtoValidator
|
||||
public class CreateRoleDtoValidator : Validator<CreateRoleDto>
|
||||
{
|
||||
|
||||
public CreateRoleDtoValidator()
|
||||
{
|
||||
RuleFor(x => x.Libelle)
|
||||
.NotEmpty()
|
||||
.WithMessage("Libelle cannot be empty")
|
||||
.MaximumLength(50)
|
||||
.WithMessage("Libelle maximum length is 50");
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,15 @@
|
||||
using FastEndpoints;
|
||||
using FluentValidation;
|
||||
using Knots.DTO.Role;
|
||||
|
||||
namespace Knots.Validators.Role;
|
||||
|
||||
public class DeleteRoleDtoValidator
|
||||
public class DeleteRoleDtoValidator : Validator<DeleteRoleDto>
|
||||
{
|
||||
|
||||
public DeleteRoleDtoValidator()
|
||||
{
|
||||
RuleFor(x => x.Id)
|
||||
.NotEmpty()
|
||||
.WithMessage("Id cannot be empty");
|
||||
}
|
||||
}
|
||||
@@ -1,6 +1,17 @@
|
||||
using FastEndpoints;
|
||||
using FluentValidation;
|
||||
using Knots.DTO.Role;
|
||||
|
||||
namespace Knots.Validators.Role;
|
||||
|
||||
public class GetRoleDtoValidator
|
||||
public class GetRoleDtoValidator : Validator<GetRoleDto>
|
||||
{
|
||||
|
||||
public GetRoleDtoValidator()
|
||||
{
|
||||
RuleFor(x => x.Libelle)
|
||||
.NotEmpty()
|
||||
.WithMessage("Libelle cannot be empty")
|
||||
.MaximumLength(50)
|
||||
.WithMessage("Libelle maximum length is 50");
|
||||
}
|
||||
}
|
||||
@@ -13,7 +13,7 @@ using System.Reflection;
|
||||
[assembly: System.Reflection.AssemblyCompanyAttribute("Knots")]
|
||||
[assembly: System.Reflection.AssemblyConfigurationAttribute("Debug")]
|
||||
[assembly: System.Reflection.AssemblyFileVersionAttribute("1.0.0.0")]
|
||||
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+dc9aa8c840b4064bd32793b90b273caaf36c360f")]
|
||||
[assembly: System.Reflection.AssemblyInformationalVersionAttribute("1.0.0+3a833724031a4e7076b11dcb48bd7aa2c7376432")]
|
||||
[assembly: System.Reflection.AssemblyProductAttribute("Knots")]
|
||||
[assembly: System.Reflection.AssemblyTitleAttribute("Knots")]
|
||||
[assembly: System.Reflection.AssemblyVersionAttribute("1.0.0.0")]
|
||||
|
||||
@@ -1 +1 @@
|
||||
1b8ae9dfe4e2b2618cd70cfa49fe9679d0b7d9b1c2eb5ae991b2036ea16d6dfd
|
||||
ea906d69ee00ac134acfca751c691f6f874ba5373dc51f1200fce206bc66abe5
|
||||
|
||||
@@ -1 +1 @@
|
||||
17733319213920905
|
||||
17733307741808199
|
||||
Reference in New Issue
Block a user