public UserEventHostedService(EventAggregator eventAggregator, UserManager <ApplicationUser> userManager, EmailSenderFactory emailSenderFactory, LinkGenerator generator) : base(eventAggregator) { _userManager = userManager; _emailSenderFactory = emailSenderFactory; _generator = generator; }
public UIManageController( UserManager <ApplicationUser> userManager, SignInManager <ApplicationUser> signInManager, EmailSenderFactory emailSenderFactory, ILogger <UIManageController> logger, UrlEncoder urlEncoder, StoreRepository storeRepository, BTCPayServerEnvironment btcPayServerEnvironment, APIKeyRepository apiKeyRepository, IAuthorizationService authorizationService, Fido2Service fido2Service, LinkGenerator linkGenerator, UserService userService, UserLoginCodeService userLoginCodeService ) { _userManager = userManager; _signInManager = signInManager; _EmailSenderFactory = emailSenderFactory; _logger = logger; _urlEncoder = urlEncoder; _btcPayServerEnvironment = btcPayServerEnvironment; _apiKeyRepository = apiKeyRepository; _authorizationService = authorizationService; _fido2Service = fido2Service; _linkGenerator = linkGenerator; _userLoginCodeService = userLoginCodeService; _userService = userService; _StoreRepository = storeRepository; }
public ManageController( UserManager <ApplicationUser> userManager, SignInManager <ApplicationUser> signInManager, EmailSenderFactory emailSenderFactory, ILogger <ManageController> logger, UrlEncoder urlEncoder, BTCPayWalletProvider walletProvider, StoreRepository storeRepository, IWebHostEnvironment env, BTCPayServerEnvironment btcPayServerEnvironment, APIKeyRepository apiKeyRepository, IAuthorizationService authorizationService, LinkGenerator linkGenerator ) { _userManager = userManager; _signInManager = signInManager; _EmailSenderFactory = emailSenderFactory; _logger = logger; _urlEncoder = urlEncoder; _btcPayServerEnvironment = btcPayServerEnvironment; _apiKeyRepository = apiKeyRepository; _authorizationService = authorizationService; _linkGenerator = linkGenerator; _StoreRepository = storeRepository; }
// This method gets called by the runtime. Use this method to add services to the container. public void ConfigureServices(IServiceCollection services) { services.AddDbContext <ApplicationDbContext>(options => options.UseSqlServer( Configuration.GetConnectionString("DefaultConnection"))); services .AddIdentity <User, IdentityRole>(options => { options.Password.RequireDigit = false; options.Password.RequireLowercase = false; options.Password.RequireUppercase = false; options.Password.RequireNonAlphanumeric = false; options.Password.RequiredLength = 6; options.SignIn.RequireConfirmedEmail = false; }) .AddEntityFrameworkStores <ApplicationDbContext>() .AddDefaultTokenProviders(); services.ConfigureApplicationCookie(options => { options.LoginPath = "/Identity/Account/Login"; options.AccessDeniedPath = "/Identity/Account/AccessDenied"; }); services.PopulateGlobalConstnts(Configuration); services .AddTransient <IFlightService, FlightService>() .AddTransient <IReservationService, ReservationService>() .AddTransient <IEmailSender, EmailSender>(_ => EmailSenderFactory.Instance(Configuration)); services.AddControllersWithViews(); services.AddRazorPages(); }
static void Main(string[] args) { XmlConfigurator.Configure(); IEmailPackageSerialiser packageSerializer = null; IEmailWatcher watcher = null; IEmailSender sender = null; EmailProcessingConfigurationSection configuration = EmailProcessingConfigurationManager.Section; Console.Clear(); var client = AWSClientFactory.CreateAmazonSimpleEmailServiceClient(configuration.Amazon.Key, configuration.Amazon.Secret); var emails = client.ListVerifiedEmailAddresses(new ListVerifiedEmailAddressesRequest()); Console.WriteLine("verified emails:"); foreach (var email in emails.ListVerifiedEmailAddressesResult.VerifiedEmailAddresses) { Console.WriteLine(email); } try { if (!Directory.Exists(configuration.PickupLocation)) { Directory.CreateDirectory(configuration.PickupLocation); } if (!Directory.Exists(configuration.DeliveredLocation)) { Directory.CreateDirectory(configuration.DeliveredLocation); } if (!Directory.Exists(configuration.FailedLocation)) { Directory.CreateDirectory(configuration.FailedLocation); } packageSerializer = new EmailPackageSerialiser(); watcher = new EmailWatcher(packageSerializer); sender = EmailSenderFactory.CreateSenderFromConfiguration(); watcher.OnMailToSend += sender.SendMail; Console.WriteLine("Watching " + configuration.PickupLocation + ". Press Esc to stop"); watcher.StartWatching(); ConsoleKeyInfo key = new ConsoleKeyInfo(); while (key.Key != ConsoleKey.Escape) { key = Console.ReadKey(); } } finally { if (watcher != null) { watcher.Dispose(); } } }
public StoreEmailRuleProcessorSender(StoreRepository storeRepository, EventAggregator eventAggregator, ILogger <InvoiceEventSaverService> logger, EmailSenderFactory emailSenderFactory, LinkGenerator linkGenerator, BTCPayServerEnvironment environment) : base( eventAggregator, logger) { _storeRepository = storeRepository; _emailSenderFactory = emailSenderFactory; _linkGenerator = linkGenerator; _environment = environment; }
public InvoiceNotificationManager( IBackgroundJobClient jobClient, EventAggregator eventAggregator, InvoiceRepository invoiceRepository, BTCPayNetworkProvider networkProvider, ILogger <InvoiceNotificationManager> logger, EmailSenderFactory emailSenderFactory) { _JobClient = jobClient; _EventAggregator = eventAggregator; _InvoiceRepository = invoiceRepository; _NetworkProvider = networkProvider; _EmailSenderFactory = emailSenderFactory; }
public InvoiceNotificationManager( IHttpClientFactory httpClientFactory, IBackgroundJobClient jobClient, EventAggregator eventAggregator, InvoiceRepository invoiceRepository, BTCPayNetworkProvider networkProvider, EmailSenderFactory emailSenderFactory) { _Client = httpClientFactory.CreateClient(); _JobClient = jobClient; _EventAggregator = eventAggregator; _InvoiceRepository = invoiceRepository; _EmailSenderFactory = emailSenderFactory; }
public BitpayIPNSender( IHttpClientFactory httpClientFactory, IBackgroundJobClient jobClient, EventAggregator eventAggregator, InvoiceRepository invoiceRepository, StoreRepository storeRepository, EmailSenderFactory emailSenderFactory) { _Client = httpClientFactory.CreateClient(); _JobClient = jobClient; _EventAggregator = eventAggregator; _InvoiceRepository = invoiceRepository; _EmailSenderFactory = emailSenderFactory; _StoreRepository = storeRepository; }
public AppsController( UserManager <ApplicationUser> userManager, ApplicationDbContextFactory contextFactory, EventAggregator eventAggregator, BTCPayNetworkProvider networkProvider, CurrencyNameTable currencies, EmailSenderFactory emailSenderFactory, AppService AppService) { _UserManager = userManager; _ContextFactory = contextFactory; _EventAggregator = eventAggregator; _NetworkProvider = networkProvider; _currencies = currencies; _emailSenderFactory = emailSenderFactory; _AppService = AppService; }
public AccountController( UserManager <ApplicationUser> userManager, RoleManager <IdentityRole> roleManager, StoreRepository storeRepository, SignInManager <ApplicationUser> signInManager, EmailSenderFactory emailSenderFactory, SettingsRepository settingsRepository, Configuration.BTCPayServerOptions options) { this.storeRepository = storeRepository; _userManager = userManager; _signInManager = signInManager; _EmailSenderFactory = emailSenderFactory; _RoleManager = roleManager; _SettingsRepository = settingsRepository; _Options = options; _logger = Logs.PayServer; }
public ManageController( UserManager <ApplicationUser> userManager, SignInManager <ApplicationUser> signInManager, EmailSenderFactory emailSenderFactory, ILogger <ManageController> logger, UrlEncoder urlEncoder, TokenRepository tokenRepository, BTCPayWalletProvider walletProvider, StoreRepository storeRepository, IHostingEnvironment env) { _userManager = userManager; _signInManager = signInManager; _EmailSenderFactory = emailSenderFactory; _logger = logger; _urlEncoder = urlEncoder; _TokenRepository = tokenRepository; _Env = env; _StoreRepository = storeRepository; }
public ManageController( UserManager <ApplicationUser> userManager, SignInManager <ApplicationUser> signInManager, EmailSenderFactory emailSenderFactory, ILogger <ManageController> logger, UrlEncoder urlEncoder, BTCPayWalletProvider walletProvider, StoreRepository storeRepository, IWebHostEnvironment env, U2FService u2FService, BTCPayServerEnvironment btcPayServerEnvironment) { _userManager = userManager; _signInManager = signInManager; _EmailSenderFactory = emailSenderFactory; _logger = logger; _urlEncoder = urlEncoder; _Env = env; _u2FService = u2FService; _btcPayServerEnvironment = btcPayServerEnvironment; _StoreRepository = storeRepository; }
public AccountController( UserManager <ApplicationUser> userManager, RoleManager <IdentityRole> roleManager, StoreRepository storeRepository, SignInManager <ApplicationUser> signInManager, EmailSenderFactory emailSenderFactory, SettingsRepository settingsRepository, Configuration.BTCPayServerOptions options, BTCPayServerEnvironment btcPayServerEnvironment, U2FService u2FService, EventAggregator eventAggregator) { this.storeRepository = storeRepository; _userManager = userManager; _signInManager = signInManager; _EmailSenderFactory = emailSenderFactory; _RoleManager = roleManager; _SettingsRepository = settingsRepository; _Options = options; _btcPayServerEnvironment = btcPayServerEnvironment; _u2FService = u2FService; _eventAggregator = eventAggregator; _logger = Logs.PayServer; }
public GreenfieldStoreEmailController(EmailSenderFactory emailSenderFactory, StoreRepository storeRepository) { _emailSenderFactory = emailSenderFactory; _storeRepository = storeRepository; }
public GreenfieldStoreEmailController(EmailSenderFactory emailSenderFactory) { _emailSenderFactory = emailSenderFactory; }