This repository was archived by the owner on Apr 17, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -362,4 +362,15 @@ public static IServiceCollection AddRedisCacheService(this IServiceCollection se
362362 return services ;
363363 }
364364 #endregion
365+
366+ #region "FLUENT VALIDATION"
367+ public static IServiceCollection AddFluentValidationService < TAssembly > ( this IServiceCollection services ) where TAssembly : class
368+ {
369+ services . AddScoped < IValidation , Validazione . Validation > ( ) ;
370+ services . AddScoped < ILoggerService , LoggerService > ( ) ;
371+ services . AddValidatorsFromAssemblyContaining < TAssembly > ( ) ;
372+
373+ return services ;
374+ }
375+ #endregion
365376}
Original file line number Diff line number Diff line change 1010global using System . Text . Json . Serialization ;
1111global using System . Threading ;
1212global using System . Threading . Tasks ;
13+ global using FluentValidation ;
1314global using FluentValidation . Results ;
1415global using MailKit . Net . Smtp ;
1516global using MailKit . Security ;
4041global using NET6CustomLibrary . EFCore . Core . Interfaces ;
4142global using NET6CustomLibrary . EFCore . Infrastructure . Interfaces ;
4243global using NET6CustomLibrary . EFCore . Infrastructure . Repository ;
43- global using NET6CustomLibrary . Errors . Interfaces ;
4444global using NET6CustomLibrary . MailKit . Options ;
4545global using NET6CustomLibrary . MailKit . Services ;
4646global using NET6CustomLibrary . MultiLanguage ;
You can’t perform that action at this time.
0 commit comments