Du kan inte välja fler än 25 ämnen Ämnen måste starta med en bokstav eller siffra, kan innehålla bindestreck ('-') och vara max 35 tecken långa.

BusinessConfigurationExtension.cs 1.6KB

12345678910111213141516171819202122232425262728293031323334353637
  1. namespace Diligent.WebAPI.Host.Extensions
  2. {
  3. public static class BusinessConfigurationExtension
  4. {
  5. /// <summary>
  6. /// Services configuration
  7. /// </summary>
  8. public static void ConfigureBusiness(this WebApplicationBuilder builder)
  9. {
  10. IServiceCollection services = builder.Services;
  11. services.AddAutoMapper(typeof(CompanyMappingProfile));
  12. services.AddAutoMapper(typeof(WebhookMappingProfile));
  13. services.AddAutoMapper(typeof(InsurerMappingProfile));
  14. services.AddAutoMapper(typeof(ApplicantMappingProfile));
  15. services.AddScoped<IInsurersService, InsurersService>();
  16. services.AddScoped<IEmailer, Emailer>();
  17. services.AddScoped<IInsuranceCompaniesService, InsuranceCompaniesService>();
  18. services.AddScoped<IInsurancePoliciesService, InsurancePoliciesService>();
  19. services.AddScoped<IWebhookSubscriptionService, WebhookSubscriptionService>();
  20. services.AddScoped<IWebhookDefinitionService, WebhookDefinitionService>();
  21. services.AddScoped<IWebhookPublisherService, WebhookPublisherService>();
  22. services.AddScoped<IWebhookPublisherService, WebhookPublisherService>();
  23. services.AddScoped<IApplicantService, ApplicantService>();
  24. services.AddScoped<IAdService, AdService>();
  25. services.AddScoped<ITechnologyService, TechnologyService>();
  26. }
  27. /// <summary>
  28. /// App configuration
  29. /// </summary>
  30. public static void ConfigureBusiness(this WebApplication app)
  31. {
  32. //
  33. }
  34. }
  35. }