forked from ddrilling/AsbCloudServer
CS2-125: Added newly created dto validators in DependencyInjection
This commit is contained in:
parent
9792fe2196
commit
d1440ea0d0
@ -79,6 +79,8 @@ namespace AsbCloudInfrastructure
|
||||
services.AddTransient<ITelemetryDataService<TelemetryDataSaubDto>, TelemetryDataSaubService>();
|
||||
services.AddTransient<ITelemetryDataService<TelemetryDataSpinDto>, TelemetryDataSpinService>();
|
||||
|
||||
services.AddValidators();
|
||||
|
||||
return services;
|
||||
}
|
||||
|
||||
|
@ -7,11 +7,25 @@ namespace AsbCloudInfrastructure.Validators
|
||||
{
|
||||
public static class DependencyInjection
|
||||
{
|
||||
public static IServiceCollection AddValidators(this IServiceCollection services,
|
||||
IConfiguration configuration)
|
||||
public static IServiceCollection AddValidators(this IServiceCollection services)
|
||||
{
|
||||
services.AddTransient<IValidator<AuthDto>, AuthDtoValidator>();
|
||||
|
||||
services.AddTransient<IValidator<ClusterDto>, ClusterDtoValidator>();
|
||||
services.AddTransient<IValidator<CompanyDto>, CompanyDtoValidator>();
|
||||
services.AddTransient<IValidator<DepositDto>, DepositDtoValidator>();
|
||||
services.AddTransient<IValidator<DrillFlowChartDto>, DrillFlowChartDtoValidator>();
|
||||
services.AddTransient<IValidator<EventDto>, EventDtoValidator>();
|
||||
services.AddTransient<IValidator<FileInfoDto>, FileInfoDtoValidator>();
|
||||
services.AddTransient<IValidator<FileMarkDto>, FileMarkDtoValidator>();
|
||||
services.AddTransient<IValidator<MeasureDto>, MeasureDtoValidator>();
|
||||
services.AddTransient<IValidator<MessageDto>, MessageDtoValidator>();
|
||||
services.AddTransient<IValidator<PermissionDto>, PermissionDtoValidator>();
|
||||
services.AddTransient<IValidator<ReportPropertiesDto>, ReportPropertiesDtoValidator>();
|
||||
services.AddTransient<IValidator<UserRegistrationDto>, UserRegistrationDtoValidator>();
|
||||
services.AddTransient<IValidator<UserRoleDto>, UserRoleDtoValidator>();
|
||||
services.AddTransient<IValidator<WellDto>, WellDtoValidator>();
|
||||
services.AddTransient<IValidator<WellOperationDto>, WellOperationDtoValidator>();
|
||||
|
||||
return services;
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user