Exemple #1
0
 public CampaignSettingsRepository(ISqlServerTenantDbContext dbContext,
                                   IFullTextSearchConditionBuilder searchConditionBuilder, IMapper mapper)
 {
     _dbContext = dbContext;
     _searchConditionBuilder = searchConditionBuilder;
     _mapper = mapper;
 }
Exemple #2
0
 /// <summary>Initializes a new instance of the <see cref="LandmarkProductRepository" /> class.</summary>
 /// <param name="dbContext">The database context.</param>
 /// <param name="searchConditionBuilder">The search condition builder.</param>
 /// <param name="mapper">The mapper.</param>
 /// <param name="clock">The clock.</param>
 public LandmarkProductRepository(
     ISqlServerTenantDbContext dbContext,
     IFullTextSearchConditionBuilder searchConditionBuilder,
     IMapper mapper,
     IClock clock)
     : base(dbContext, searchConditionBuilder, mapper, clock)
 {
     _dbContext = dbContext;
 }
Exemple #3
0
 public ProductRepository(
     ISqlServerTenantDbContext dbContext,
     IFullTextSearchConditionBuilder searchConditionBuilder,
     IMapper mapper,
     IClock clock)
 {
     _dbContext = dbContext;
     _searchConditionBuilder = searchConditionBuilder;
     _mapper = mapper;
     _clock  = clock;
 }
Exemple #4
0
 public RunRepository(ISqlServerTenantDbContext dbContext,
                      IFullTextSearchConditionBuilder searchConditionBuilder,
                      ISqlServerSalesAreaByIdCacheAccessor salesAreaByIdCache,
                      ISqlServerSalesAreaByNameCacheAccessor salesAreaByNameCache,
                      IMapper mapper)
 {
     _dbContext = dbContext;
     _searchConditionBuilder = searchConditionBuilder;
     _salesAreaByIdCache     = salesAreaByIdCache;
     _salesAreaByNameCache   = salesAreaByNameCache;
     _mapper = mapper;
 }
 /// <summary>Initializes a new instance of the <see cref="LandmarkCampaignRepository" /> class.</summary>
 /// <param name="dbContext">The database context.</param>
 /// <param name="searchConditionBuilder">The search condition builder.</param>
 /// <param name="identityGenerator">The identity generator.</param>
 /// <param name="mapper">The mapper.</param>
 public LandmarkCampaignRepository(
     ISqlServerLongRunningTenantDbContext dbContext,
     IFullTextSearchConditionBuilder searchConditionBuilder,
     IIdentityGenerator identityGenerator,
     ISqlServerSalesAreaByIdCacheAccessor salesAreaByIdCache,
     ISqlServerSalesAreaByNameCacheAccessor salesAreaByNameCache,
     IMapper mapper)
     : base(dbContext, searchConditionBuilder, identityGenerator, salesAreaByIdCache, salesAreaByNameCache, mapper)
 {
     _dbContext = dbContext;
     _searchConditionBuilder = searchConditionBuilder;
 }
Exemple #6
0
        public static IFullTextSearchConditionBuilder StartAllWith(this IFullTextSearchConditionBuilder builder, params string[] values)
        {
            if (values?.Any() ?? false)
            {
                var b = builder.StartWith(values.First());
                foreach (var value in values.Skip(1))
                {
                    builder = b.And();
                    b       = builder.StartWith(value);
                }
            }

            return(builder);
        }
Exemple #7
0
 public CampaignRepository(ISqlServerLongRunningTenantDbContext dbContext,
                           IFullTextSearchConditionBuilder searchConditionBuilder,
                           IIdentityGenerator identityGenerator,
                           ISqlServerSalesAreaByIdCacheAccessor salesAreaByIdCache,
                           ISqlServerSalesAreaByNameCacheAccessor salesAreaByNameCache,
                           IMapper mapper)
 {
     _dbContext = dbContext;
     _searchConditionBuilder = searchConditionBuilder;
     _identityGenerator      = identityGenerator;
     _sequenceRebuilder      = new SequenceRebuilder <Entities.Tenant.Campaigns.Campaign, CampaignNoIdentity>();
     _salesAreaByIdCache     = salesAreaByIdCache;
     _salesAreaByNameCache   = salesAreaByNameCache;
     _mapper = mapper;
 }
Exemple #8
0
 public ProgrammeRepository(
     ISqlServerTenantDbContext dbContext,
     ISqlServerDbContextFactory <ISqlServerTenantDbContext> dbContextFactory,
     IFullTextSearchConditionBuilder searchConditionBuilder,
     ISqlServerSalesAreaByIdCacheAccessor salesAreaByIdCache,
     ISqlServerSalesAreaByNameCacheAccessor salesAreaByNameCache,
     IMapper mapper)
 {
     _dbContext              = dbContext;
     _dbContextFactory       = dbContextFactory;
     _searchConditionBuilder = searchConditionBuilder;
     _salesAreaByIdCache     = salesAreaByIdCache;
     _salesAreaByNameCache   = salesAreaByNameCache;
     _mapper = mapper;
     _programmeDictionaryCache =
         new ProgrammeDictionaryCache(_dbContext, preloadData: false);
     _programmeCategoryCache = new ProgrammeCategoryCache(_dbContext);
 }