Esempio n. 1
0
 public LeadScoreJob(
     ILeadScoreRuleService leadScoreRuleService,
     ILeadScoreService leadScoreService,
     IAccountService accountService,
     IMessageService messageService)
 {
     _leadScoreRuleService = leadScoreRuleService;
     _leadScoreService     = leadScoreService;
     _accountService       = accountService;
     _messageService       = messageService;
 }
Esempio n. 2
0
 public LeadScoreProcessor(CronJobDb cronJob, JobService jobService, string leadScoreProcessorCacheName)
     : base(cronJob, jobService, leadScoreProcessorCacheName)
 {
     this.indexingService      = IoC.Container.GetInstance <IIndexingService>();
     this.contactService       = IoC.Container.GetInstance <IContactService>();
     this.searchService        = IoC.Container.GetInstance <ISearchService <Contact> >();
     this.leadScoreRuleService = IoC.Container.GetInstance <ILeadScoreRuleService>();
     this.leadScoreService     = IoC.Container.GetInstance <ILeadScoreService>();
     this.accountService       = IoC.Container.GetInstance <IAccountService>();
     this.messageService       = IoC.Container.GetInstance <IMessageService>();
 }
        public void Initialize()
        {
            InitializeAutoMapper.Initialize();
            mockRepository = new MockRepository(MockBehavior.Default);
            IUnitOfWork mockUnitOfWork = mockRepository.Create <IUnitOfWork>().Object;

            mockLeadScoreRuleRepository = mockRepository.Create <ILeadScoreRuleRepository>();
            mockTagRepository           = mockRepository.Create <ITagRepository>();
            mockCampaignRepository      = mockRepository.Create <ICampaignRepository>();
            mockFormRepository          = mockRepository.Create <IFormRepository>();
            mockCachingService          = mockRepository.Create <ICachingService>();
            indexingService             = mockRepository.Create <IIndexingService>();
            tagService           = mockRepository.Create <ITagService>();
            leadScoreRuleService = new LeadScoreRuleService(mockLeadScoreRuleRepository.Object, mockTagRepository.Object, mockCampaignRepository.Object, mockCachingService.Object, mockFormRepository.Object, mockUnitOfWork, tagService.Object, indexingService.Object);
        }
Esempio n. 4
0
 public LeadScoreService(ILeadScoreRepository leadScoreRepository,
                         ILeadScoreRuleService leadScoreRuleService, IUnitOfWork unitOfWork, IMessageService messageService, IContactService contactService, IIndexingService indexingService,
                         IContactRepository contactRepository, IAccountService accountService)
 {
     //intentionally skipped to write the logic when contactRepository and unitOfWork are null to know when this is actually required;
     if (unitOfWork == null)
     {
         throw new ArgumentNullException("unitOfWork");
     }
     this.leadScoreRepository  = leadScoreRepository;
     this.unitOfWork           = unitOfWork;
     this.leadScoreRuleService = leadScoreRuleService;
     this.contactService       = contactService;
     this.indexingService      = indexingService;
     this.contactRepository    = contactRepository;
     this.messageService       = messageService;
     this.accountService       = accountService;
 }
Esempio n. 5
0
 public LeadScoreController(ILeadScoreRuleService leadScoreService, ICachingService cachingService)
 {
     this.leadScoreService = leadScoreService;
     this.cachingService   = cachingService;
 }
Esempio n. 6
0
 public MessageHandler()
 {
     this.leadScoreRuleService = IoC.Container.GetInstance <ILeadScoreRuleService>();
     this.leadScoreService     = IoC.Container.GetInstance <ILeadScoreService>();
 }