public static IServiceCollection AddEfSupplyContext( this IServiceCollection services, SupplyDataContextSettings settings) { services.AddSingleton(settings); services.AddSingleton <IInvoceRepository, InvoceRepository>(); services.AddSingleton <IContextFactory <SupplyDataContext>, SupplyContextFactory>(); return(services); }
public SupplyDataContext(SupplyDataContextSettings settings) { _settings = settings; }