using Microsoft.Extensions.DependencyInjection; using Microsoft.Extensions.DependencyInjection.Extensions; using WorkFlow.Application.Contracts; using WorkFlow.Application.Services; using WorkFlow.Infrastructure; namespace WorkFlow.Application { public static class DIExtensions { public static IServiceCollection AddWorkFlowServices(this IServiceCollection services) { services.AddAutoMapper(typeof(MappingProfile).Assembly); services.TryAddScoped(); services.TryAddScoped(); services.TryAddScoped(); services.TryAddScoped(); services.TryAddScoped(); return services; } public static IServiceCollection AddWorkFlow(this IServiceCollection services) => services.AddWorkFlowRepositories().AddWorkFlowServices(); } }