public async Task Execute(IJobExecutionContext context) { IUnityContainer container = new UnityContainer(); IPetRepository PetRepo = container.Resolve <PetRepository>(); IUserRepository UserRepo = container.Resolve <UserRepository>(); IServiceRepository ServiceRepo = container.Resolve <ServiceRepository>(); IEmailRepository EmailRepo = container.Resolve <EmailRepository>(); var List = ServiceRepo.GetAllListOfElements(); List <Service> res = new List <Service>(); foreach (var i in List) { DateTime dateser = DateTime.Parse(i.DateTimeService); TimeSpan span = dateser.Subtract(DateTime.Now); if (dateser.Day > DateTime.Now.Day && (int)span.TotalHours < 35) { string to = UserRepo.GetElementsById(PetRepo.GetElementsById(i.IDPet.ToString()).OwnerId.ToString()).Email; string body = "Здравствуйте уважаемый клиент! Напоминаем, что вы записаны на прием " + dateser.ToString("dd.MM.yyyy") + " в " + dateser.ToString("HH:mm") + ". "; { await EmailRepo.SendEmail("СЮДА СВОЙ ЕМАЙИЛ", "СЮДА ПАРОЛЬЕМАЙЛА", to, "Напоминание о приеме на завтра", body); } } } }
public EmailProvider(IServiceProvider services, IContextLock access, SmallWorldOptions options, IEmailRepository emails) { this.services = services; this.options = options; this.emails = emails; this.access = access; }
public EMailHandler(IConfiguration _configuration) { var factory = new ProcessorFactoryResolver <IEmailRepository>(_configuration); emailRepository = factory.CreateProcessor(); configuration = _configuration; }
public PersonController(IPhoneRepository phone, IPersonRepository person, IEmailRepository email, ILogRepository log) { _phone = phone; _email = email; _person = person; _log = log; }
public DashBoardService(IUserRepository IUserRepository, IEmailRepository IEmailRepository, IOrderRepository IOrderRepository, IRemarksRepository IRemarksRepository) { _iUserRepository = IUserRepository; _iEmailRepository = IEmailRepository; _iOrderRepository = IOrderRepository; _iRemarksRepository = IRemarksRepository; }
public EmailSendingJob(IOptions <MailSetting> mailsettings, IEmailRepository emailRepository, IEmailService emailService) { _emailService = emailService; _emailRepository = emailRepository; _mailsettings = mailsettings.Value; }
public VerlanglijstController(IGebruikerRepository gebruikerRepository, IProductRepository productRepository, IEmailRepository emailRepository) { this.productRepository = productRepository; this.gebruikerRepository = gebruikerRepository; this.emailRepository = emailRepository; viewModelFactory = new ViewModelFactory(); }
public EmailProcessor( IEmailRepository emailRepository, IEnumerable <IEmailSender> emailSenders, ILogger <EmailProcessor> logger) { this.emailRepository = emailRepository; this.emailSenders = emailSenders; this.logger = logger; }
public UserController(IUserRepository user, IPermissionRepository permission, IRoleRepository role, IEmailRepository email) { _user = user; _permission = permission; _role = role; _email = email; }
private string BuildEmailDetailsPage(IEmailRepository emailRepository, string emailId) { EmailMessage email = null; foreach (var item in emailRepository.ReceivedMessages) { if (item.Guid.ToString() == emailId) { email = item; break; } } if (email == null) { return("Invalid email id"); } StringBuilder pageBody = new StringBuilder(); pageBody.Append(ReadResourceFromAssembly("SmtpMoq.Resources.EmailDetails.html")); pageBody.Replace("***fromemail***", email.From); pageBody.Replace("***toemail***", email.RecipientsCommaSeparated); pageBody.Replace("***emaildata***", email.Data); return(pageBody.ToString()); }
public PessoaRepository(RouteContext context) : base(context) { enderecoRepository = new EnderecoRepository(Context); telefoneRepository = new TelefoneRepository(Context); emailRepository = new EmailRepository(Context); agendaRepository = new AgendaRepository(Context); }
public OrderRepository(IProductRepository productRepository, IPaymentSeriveRepository paymentSeriveRepository, IEmailRepository emailRepository) { errors = new List <string>(); _productRepository = productRepository; _paymentSeriveRepository = paymentSeriveRepository; _emailRepository = emailRepository; }
public EmailManager(IEmailRepository emailRepository, IOptions <TeamBinsAppSettings> settings, ITeamRepository teamRepository) { this._teamRepository = teamRepository; this._emailRepository = emailRepository; this._settings = settings.Value; }
public BulkEmailViewModel(INavigationManager navigation, IUnitOfWorkFactory unitOfWorkFactory, Func <IUnitOfWork, IQueryOver <Order> > itemsSourceQueryFunction, IEmailParametersProvider emailParametersProvider, ICommonServices commonServices, IAttachmentsViewModelFactory attachmentsViewModelFactory, Employee author, IEmailRepository emailRepository) : base(navigation) { _uow = (unitOfWorkFactory ?? throw new ArgumentNullException(nameof(unitOfWorkFactory))).CreateWithoutRoot(); _emailParametersProvider = emailParametersProvider ?? throw new ArgumentNullException(nameof(emailParametersProvider)); _commonServices = commonServices ?? throw new ArgumentNullException(nameof(commonServices)); _author = author ?? throw new ArgumentNullException(nameof(author)); _emailRepository = emailRepository ?? throw new ArgumentNullException(nameof(emailRepository)); _instanceId = emailRepository.GetCurrentDatabaseId(_uow); _configuration = _uow.GetAll <InstanceMailingConfiguration>().FirstOrDefault(); AttachmentsEmailViewModel = attachmentsViewModelFactory.CreateNewAttachmentsViewModel(ObservableAttachments); ObservableAttachments.ListContentChanged += ObservableAttachments_ListContentChanged; var itemsSourceQuery = itemsSourceQueryFunction.Invoke(_uow); _debtorJournalNodes = itemsSourceQuery.List <DebtorJournalNode>(); MailSubject = string.Empty; Init(); }
public EmailOutbox(IEmailDispatcher dispatcher, IMailMessageCreator messageCreator, IEmailRepository repository, ILogger <EmailOutbox> log) { Dispatcher = dispatcher; MessageCreator = messageCreator; Repository = repository; Log = log; }
public LoginServiceImpl(ILoginRepository loginRepository, IEmailRepository emailRepository, IMail mail) { repository = loginRepository; this.emailRepository = emailRepository; this.mail = mail; this.constituentRepository = constituentRepository; }
// C o n s t r u c t o r s public HomeController(ILogger <HomeController> logger, IEmailRepository emailRepo, IPetRepository petRepository, IUserRepository userRepository) { _logger = logger; _emailRepo = emailRepo; _petRepository = petRepository; _userRepository = userRepository; }
public void SetUp() { unitOfWork = Substitute.For <IUnitOfWork>(); emailRepository = Substitute.For <IEmailRepository>(); unitOfWork.EmailRepository.ReturnsForAnyArgs(emailRepository); getEmailUseCase = new GetEmailUseCase(unitOfWork); }
public ContactListService(IContactRepository contactRepository, IEmailRepository emailRepository, IPhoneRepository phoneRepository, ITagRepository tagRepository) { this.contactRepository = contactRepository; this.emailRepository = emailRepository; this.phoneRepository = phoneRepository; this.tagRepository = tagRepository; }
public EmailManager( IPersonRepository personRepo, IPersonEmailRepository personEmailRepository, IEmailAccountRepository emailAccountRepository, IEmailRepository emailRepository, IEmailSettingsRepository emailSettingsRepository, IOrganizationManager organizationManager, IHttpContextAccessor httpContextAccessor, IEmailAttachmentRepository emailAttachmentRepository, IFileManager fileManager, IStorageDriveRepository storageDriveRepository, IStorageFileRepository storageFileRepository) { _personRepo = personRepo; _personEmailRepository = personEmailRepository; _emailAccountRepository = emailAccountRepository; _emailRepository = emailRepository; _emailSettingsRepository = emailSettingsRepository; _organizationManager = organizationManager; _httpContextAccessor = httpContextAccessor; _emailAttachmentRepository = emailAttachmentRepository; _fileManager = fileManager; _storageDriveRepository = storageDriveRepository; _storageFileRepository = storageFileRepository; }
public EmailManager(IEmailRepository emailRepository, IOptions<AppSettings> settings, ITeamRepository teamRepository) { this._teamRepository = teamRepository; this._emailRepository = emailRepository; this._settings = settings.Value; }
public EmailService(IEmailRepository emailRepository, ICustomerRepository customerRepository, IUnitOfWork uow, IEmployeeRepository employeeRepository) : this(emailRepository, uow) { this._customerRepository = customerRepository; _employeeRepository = employeeRepository; }
public EmailService(IEmailBodyFormatter emailBodyFormatter, IWebDataScrapingService webDataScrappingService, IEmailRepository emailRepository, IEmailSender emailSender) { _emailBodyFormatter = emailBodyFormatter; _webDataScrapingService = webDataScrappingService; _emailRepository = emailRepository; _emailSender = emailSender; }
public EmailService(IEmailTemplateService templateService, IEmailRepository emailRepository) { Ensure.That(() => templateService).IsNotNull(); Ensure.That(() => emailRepository).IsNotNull(); this.templateService = templateService; this.emailRepository = emailRepository; }
public EmailRecorder(ISmtpServer smtpServer, IEmailRepository emailRepository, IGroupRepository groupRepository) { _smtpServer = smtpServer; _emailRepository = emailRepository; _groupRepository = groupRepository; RecordMail(); }
public EmailService(IEmailRepository emailRepository, IReferenceGenerator referenceGenerator) { Check.If(emailRepository).IsNotNull(); Check.If(referenceGenerator).IsNotNull(); _emailRepository = emailRepository; _referenceGenerator = referenceGenerator; }
public SendEmailController(IInspectionRepository inspectionRepository, IMistakeRepository mistakeRepository, IEmailRepository emailRepository) { _inspectionRepository = inspectionRepository; _mistakeRepository = mistakeRepository; _emailRepository = emailRepository; }
private static void Setup() { IKernel kernel = new StandardKernel(new BindingModule()); _messageQueue = kernel.Get <IMessageQueue>(); _emailRepository = kernel.Get <IEmailRepository>(); _bucket = kernel.Get <IFileStorageProvider>(); }
public EmailController(IOptions <GmailSettings> gmailConfig, IDatingRepository repo, IEmailRepository repoEmail) { _gmailConfig = gmailConfig; _userName = _gmailConfig.Value.UserName; _password = _gmailConfig.Value.ApiSecret; _repo = repo; _repoEmail = repoEmail; }
public EmailController(ILogger <EmailController> logger, IConfiguration configuration, EmailContext context) { _logger = logger; _configuration = configuration; _templatesRepository = new EmailTemplatesRepository(context); _emailRepository = new MailKitRepository(configuration); _emailHistoryRepository = new EmailHistoryRepository(context); }
public EmailRepositoryTest() { _mockService = new Mock <IMongoService>(); _mockMapper = new Mock <IMapper>(); _mockConfiguration = new Mock <IConfiguration>(); _emailRepository = new EmailRepository(_mockService.Object, _mockConfiguration.Object, _mockMapper.Object); }
public EmailService(IEmailRepository emailRepository) { _emailRepository = emailRepository; if (!string.IsNullOrEmpty(CurrentUser.DbName)) { this._dbName = CurrentUser.DbName; } }
public EmailService(IChapterRepository chapterRepository, IEmailRepository emailRepository, IMailProvider mailProvider, IMemberRepository memberRepository) { _chapterRepository = chapterRepository; _emailRepository = emailRepository; _mailProvider = mailProvider; _memberRepository = memberRepository; }
public SmtpServer(SmtpServerSettings settings, IEmailRepository emailRepository, ILogger logger) { this.Settings = settings; this.emailRepository = emailRepository; this.logger = logger; this.smtpListener = null; this.connectionsToDispose = new SynchronizedCollection <TcpClient>(); }
public OrdersController() { _productDal = new ProductDAL(); _productRepository = new ProductRepository(_productDal); _paymentSeriveRepository = new PaymentSeriveRepository(); _emailRepository = new EmailRepository(); _orderRepository = new OrderRepository(_productRepository, _paymentSeriveRepository, _emailRepository); }
public UserAccountManager(IUserRepository userRepository, IUserAuthHelper userSessionHelper, IProjectManager projectManager, ITeamRepository teamRepository, IEmailManager emailManager, IEmailRepository emailRepository, IOptions<AppSettings> settings) { this.emailManager = emailManager; this.userRepository = userRepository; this.userSessionHelper = userSessionHelper; this.projectManager = projectManager; this.teamRepository = teamRepository; this.emailRepository = emailRepository; this._settings = settings.Value; }
public CommentManager(ICommentRepository commentRepository,IUserAuthHelper userSessionHelper, IIssueRepository issueRepository, IActivityRepository activityRepository,IEmailManager emailManager,ITeamRepository teamRepository,IEmailRepository emailRepository, IOptions<AppSettings> settings) { this._settings = settings.Value; this._emailRepository = emailRepository; this._teamRepository = teamRepository; this._emailManager = emailManager; this._commentRepository = commentRepository; this._userSessionHelper = userSessionHelper; this._issueRepository = issueRepository; this._activityRepository = activityRepository; }
public ValidationService(IEmailRepository emailRepository, ITelephoneNumberRepository telephoneNumberRepository, IPipelinePositionGenerator pipelinePositionGenerator, IArchiveService archiveService) { Check.If(emailRepository).IsNotNull(); Check.If(telephoneNumberRepository).IsNotNull(); Check.If(pipelinePositionGenerator).IsNotNull(); Check.If(archiveService).IsNotNull(); _emailRepository = emailRepository; _telephoneNumberRepository = telephoneNumberRepository; _pipelinePositionGenerator = pipelinePositionGenerator; _archiveService = archiveService; }
public IncomingDocProcessor( Func<Owned<IUnitOfWork>> unitOfWorkFactory, IUnitOfWork unitOfWork, IDocRepository docRepository, IEmailRepository emailRepository, ICorrespondentRepository correspondentRepository, IRioObjectExtractor rioObjectExtractor, IRioDocumentParser rioDocumentParser, IRioValidator rioValidator) { this.unitOfWorkFactory = unitOfWorkFactory; this.unitOfWork = unitOfWork; this.docRepository = docRepository; this.emailRepository = emailRepository; this.correspondentRepository = correspondentRepository; this.rioObjectExtractor = rioObjectExtractor; this.rioDocumentParser = rioDocumentParser; this.rioValidator = rioValidator; }
public EmailService(IMailboxConfiguration mailboxConfiguration, IForwardService forwardService, IEmailProvider emailProvider, IEmailRepository emailRepository, IReferenceGenerator referenceGenerator, IEmailServiceSettings emailServiceSettings) { Check.If(mailboxConfiguration).IsNotNull(); Check.If(forwardService).IsNotNull(); Check.If(emailProvider).IsNotNull(); Check.If(emailRepository).IsNotNull(); Check.If(referenceGenerator).IsNotNull(); Check.If(emailServiceSettings).IsNotNull(); _mailboxConfiguration = mailboxConfiguration; _forwardService = forwardService; _emailProvider = emailProvider; _emailRepository = emailRepository; _referenceGenerator = referenceGenerator; _emailServiceSettings = emailServiceSettings; }
/// <summary> /// Inject the contructor with email for the user /// </summary> /// <param name="emailRepo"></param> public UserRepository(IEmailRepository emailRepo) { this.emailRepo = emailRepo; }
/// <summary> /// Inject the contructor with insurance dependencies /// </summary> public InsuranceRepository(IEmailRepository emailRepo, IUserRepository userRepo, IDeductibleRepository deductibleRepo) { this.userRepo = userRepo; this.emailRepo = emailRepo; this.deductibleRepo = deductibleRepo; }
public EmailBL() { this.emailRepository = new EmailRepository(); this.companyID = Convert.ToInt32(HttpContext.Current.Session["CompanyID"]); }
public EmailManager(IEmailRepository emailRepository, IGroupRepository groupRepository) { _emailRepository = emailRepository; _groupRepository = groupRepository; }
public EmailService(ILoggingService loggingService, ISettingsService settingsService, IEmailRepository emailRepository) { _loggingService = loggingService; _settingsService = settingsService; _emailRepository = emailRepository; }
public EmailManager() { unitOfWorkLive = new UnitOfWork(); emailRepository = new EmailRepository(unitOfWorkLive); lookupMgr = new LookupManager(); }
/// <summary> /// Property controller contructor to use contructor injection based on interface type /// </summary> public UserController(IUserRepository userRepo, IEmailRepository emailRepo) { this.userRepo = userRepo; this.emailRepo = emailRepo; }
public EmailService(IEmailRepository anEmailRepo) { theEmailRepository = anEmailRepo; }
public MailConnector(IEmailRepository repository) { Repository = repository; }
public void Setup() { _mockDbSettings.Setup(x => x.ConnectionString).Returns("TestConnectionString"); _mockContext.Setup(x => x.Emails).Returns(_mockDbSet.Object); _mockContext.Setup(x => x.SaveChanges()).Returns(1); _emailRepository = new EmailRepository(_mockContext.Object); }
/// <summary> /// Insurance controller contructor to use contructor injection based /// on interface type. /// </summary> /// <param name="insuranceRepo"></param> public InsuranceController(IInsuranceRepository insRepo, IUserRepository userRepo, IEmailRepository emailRepo) { this.insRepo = insRepo; this.userRepo = userRepo; this.emailRepo = emailRepo; }
public EmailService(IEmailTemplateEngine composer, IEmailProvider sender, IEmailRepository repository) { _composer = composer; _sender = sender; _repository = repository; }
public void Setup() { _mockDbSettings.Setup(x => x.ConnectionString).Returns("TestConectionString"); _mockContext.Setup(x => x.Applications).Returns(_mockDbSet.Object); _mockContext.Setup(x => x.SaveChanges()).Returns(1); _mockEmailMapper.Setup(x => x.Map(It.IsAny<Email>(), It.IsAny<Email>())).Returns(true); _emailRepository = new EmailRepository(_mockContext.Object, _mockEmailMapper.Object); }
public EmailService(IEmailRepository emailRepository) { EmailRepository = emailRepository; }
public EmailService(IEmailRepository aEmailRepository) { theEmailRepo = aEmailRepository; }