refactor(Application.Configurations): Config-Suffix in Params umbenannt.

This commit is contained in:
Developer 02
2025-01-31 12:51:44 +01:00
parent 363329ca18
commit 120c8623dd
8 changed files with 24 additions and 29 deletions

View File

@@ -1,13 +0,0 @@
namespace EnvelopeGenerator.Application.Configurations
{
public class DispatcherConfig
{
public int SendingProfile { get; init; } = 1;
public string AddedWho { get; init; } = "DDEnvelopGenerator";
public int ReminderTypeId { get; init; } = 202377;
public string EmailAttmt1 { get; init; } = string.Empty;
}
}

View File

@@ -0,0 +1,12 @@
namespace EnvelopeGenerator.Application.Configurations;
public class DispatcherParams
{
public int SendingProfile { get; init; } = 1;
public string AddedWho { get; init; } = "DDEnvelopGenerator";
public int ReminderTypeId { get; init; } = 202377;
public string EmailAttmt1 { get; init; } = string.Empty;
}

View File

@@ -1,7 +0,0 @@
namespace EnvelopeGenerator.Application.Configurations
{
public class MailConfig
{
public required Dictionary<string, string> Placeholders { get; init; }
}
}

View File

@@ -0,0 +1,6 @@
namespace EnvelopeGenerator.Application.Configurations;
public class MailParams
{
public required Dictionary<string, string> Placeholders { get; init; }
}

View File

@@ -54,8 +54,8 @@ namespace EnvelopeGenerator.Application.Extensions
services.AddAutoMapper(typeof(BasicDtoMappingProfile).Assembly);
services.AddAutoMapper(typeof(UserMappingProfile).Assembly);
services.ConfigureByTypeName<DispatcherConfig>(config);
services.ConfigureByTypeName<MailConfig>(config);
services.ConfigureByTypeName<DispatcherParams>(config);
services.ConfigureByTypeName<MailParams>(config);
services.ConfigureByTypeName<CodeGeneratorParams>(config);
services.ConfigureByTypeName<TotpSmsParams>(config);

View File

@@ -21,12 +21,12 @@ namespace EnvelopeGenerator.Application.Services
{
private readonly IEmailTemplateService _tempService;
private readonly IEnvelopeReceiverService _envRcvService;
private readonly DispatcherConfig _dConfig;
private readonly DispatcherParams _dConfig;
private readonly IConfigService _configService;
private readonly Dictionary<string, string> _placeholders;
private readonly ICodeGenerator _codeGenerator;
public EnvelopeMailService(IEmailOutRepository repository, IMapper mapper, IEmailTemplateService tempService, IEnvelopeReceiverService envelopeReceiverService, IOptions<DispatcherConfig> dispatcherConfigOptions, IConfigService configService, IOptions<MailConfig> mailConfig, ICodeGenerator codeGenerator) : base(repository, mapper)
public EnvelopeMailService(IEmailOutRepository repository, IMapper mapper, IEmailTemplateService tempService, IEnvelopeReceiverService envelopeReceiverService, IOptions<DispatcherParams> dispatcherConfigOptions, IConfigService configService, IOptions<MailParams> mailConfig, ICodeGenerator codeGenerator) : base(repository, mapper)
{
_tempService = tempService;
_envRcvService = envelopeReceiverService;