public MongoDBRepository(IServiceProvider serviceProvider, MongoDbContextBase mongoDbContext) { _mongoDbContext = mongoDbContext; _httpContextAccessor = serviceProvider.GetService <IHttpContextAccessor>(); _collection = _mongoDbContext.Collection <TData>(); Collection = _mongoDbContext.Collection <TData>(); }
//BsonDocument public MongoDBRepository(IServiceProvider serviceProvider, MongoDbContextBase mongoDbContext) { _mongoDbContext = mongoDbContext; _collection = _mongoDbContext.Collection <TEntity>(); _principal = serviceProvider.GetService <IPrincipal>(); }
public MongoDBRepository(IServiceProvider serviceProvider, MongoDbContextBase mongoDbContext) { _mongoDbContext = mongoDbContext; _collection = _mongoDbContext.Collection <TData>(); Collection = _mongoDbContext.Collection <TData>(); }
public CustomerMongoRepository(MongoDbContextBase mongoDbContext, string collectionName) : base(mongoDbContext.mongoConnectionSettings, collectionName) { }
//BsonDocument public MongoRepository(IServiceProvider serviceProvider, MongoDbContextBase mongoDbContext) { _mongoDbContext = mongoDbContext; Collection = _mongoDbContext.Collection <TEntity>(); }