Вы не можете выбрать более 25 тем Темы должны начинаться с буквы или цифры, могут содержать дефисы(-) и должны содержать не более 35 символов.

BusinessConfigurationExtension.cs 2.3KB

1234567891011121314151617181920212223242526272829303132333435363738394041424344454647
  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.AddAutoMapper(typeof(CommentMappingProfile));
  16. services.AddAutoMapper(typeof(SelectionProcessMappingProfile));
  17. services.AddAutoMapper(typeof(SelectionLevelMappingProfile));
  18. services.AddScoped<IInsurersService, InsurersService>();
  19. services.AddScoped<IEmailer, Emailer>();
  20. services.AddScoped<IHttpClientService, HttpClientService>();
  21. services.AddScoped<IInsuranceCompaniesService, InsuranceCompaniesService>();
  22. services.AddScoped<IInsurancePoliciesService, InsurancePoliciesService>();
  23. services.AddScoped<ISelectionProcessService, SelectionProcessService>();
  24. services.AddScoped<ISelectionLevelService, SelectionLevelService>();
  25. services.AddScoped<IWebhookSubscriptionService, WebhookSubscriptionService>();
  26. services.AddScoped<IWebhookDefinitionService, WebhookDefinitionService>();
  27. services.AddScoped<IWebhookPublisherService, WebhookPublisherService>();
  28. services.AddScoped<IWebhookPublisherService, WebhookPublisherService>();
  29. services.AddScoped<IApplicantService, ApplicantService>();
  30. services.AddScoped<IAuthenticationService, AuthenticationService>();
  31. services.AddScoped<IAdService, AdService>();
  32. services.AddScoped<ITechnologyService, TechnologyService>();
  33. services.AddScoped<ICommentService, CommentService>();
  34. services.AddScoped<IPatternService, PatternService>();
  35. services.AddScoped<IScheduleService, ScheduleService>();
  36. }
  37. /// <summary>
  38. /// App configuration
  39. /// </summary>
  40. public static void ConfigureBusiness(this WebApplication app)
  41. {
  42. //
  43. }
  44. }
  45. }