// TODO: This is a lot of injected dependencies...
 public WebhookHandlerService(IPaymentHandlerSubscription paymentHandlerSubscription,
                              IPaymentHandlerCustomerService paymentHandlerCustomerService,
                              IPaymentHandlerInvoice paymentHandlerInvoice,
                              IPaymentHandlerEventService paymentHandlerEvent,
                              INewMemberService newMemberService,
                              IMemberAddBillingActivityService memberAddBillingActivityService,
                              IMemberSubscriptionRenewalService memberSubscriptionRenewalService,
                              IMemberCancellationService memberCancellationService,
                              IMemberSubscriptionEndedAdminEmailService memberSubscriptionEndedAdminEmailService,
                              IUserLookupService userLookupService,
                              IRepository <Member> repository,
                              AdminUpdatesWebhook webhook,
                              IAppLogger <WebhookHandlerService> logger)
 {
     _paymentHandlerSubscription    = paymentHandlerSubscription;
     _paymentHandlerCustomerService = paymentHandlerCustomerService;
     _paymentHandlerInvoice         = paymentHandlerInvoice;
     _paymentHandlerEventService    = paymentHandlerEvent;
     _newMemberService = newMemberService;
     _memberAddBillingActivityService          = memberAddBillingActivityService;
     _memberSubscriptionRenewalService         = memberSubscriptionRenewalService;
     _memberCancellationService                = memberCancellationService;
     _memberSubscriptionEndedAdminEmailService = memberSubscriptionEndedAdminEmailService;
     _userLookupService = userLookupService;
     _repository        = repository;
     _webhook           = webhook;
     _logger            = logger;
 }
 public MemberAddBillingActivityService(IUserLookupService userLookup,
                                        IRepository <Member> memberRepository,
                                        IMemberLookupService memberLookup)
 {
     _userLookup          = userLookup;
     _memberRepository    = memberRepository;
     _memberLookupService = memberLookup;
 }
 public AlumniGraduationService(IUserLookupService userLookupService,
                                IRepository <Member> repository,
                                IGraduationCommunicationsService graduationCommunicationsService,
                                IUserRoleManager userRoleManager)
 {
     _userLookupService = userLookupService;
     _repository        = repository;
     _graduationCommunicationsService = graduationCommunicationsService;
     _userRoleManager = userRoleManager;
 }
 public HRManagementController(UserManager <ApplicationUser> userManager,
                               ICompositeViewEngine viewEngine,
                               IEnrollmentService enrollmentService,
                               ICandidateService candidateService,
                               IUserLookupService userService) : base(viewEngine)
 {
     this._userManager       = userManager;
     this._candidateService  = candidateService;
     this._enrollmentService = enrollmentService;
     this._userService       = userService;
 }
Beispiel #5
0
        public static async Task <TUser> GetByIdAsync <TUser> (this IUserLookupService <TUser> userLookupService, Guid id, CancellationToken cancellationToken = default)
            where TUser : class, IUser
        {
            var user = await userLookupService.FindByIdAsync(id, cancellationToken);

            if (user == null)
            {
                throw new EntityNotFoundException(typeof(TUser), id);
            }

            return(user);
        }
        public static async Task <TUser> GetByUserNameAsync <TUser>(this IUserLookupService <TUser> userLookupService, string userName, CancellationToken cancellationToken = default)
            where TUser : class, IUser
        {
            var user = await userLookupService.FindByUserNameAsync(userName, cancellationToken).ConfigureAwait(false);

            if (user == null)
            {
                throw new EntityNotFoundException(typeof(TUser), userName);
            }

            return(user);
        }
Beispiel #7
0
 public MemberSubscriptionCancellationService(
     IUserRoleMembershipService userRoleMembershipService,
     IEmailService emailService,
     IUserLookupService userLookup,
     IMemberLookupService memberLookup,
     IRepository <Member> memberRepository,
     IMemberSubscriptionPeriodCalculationsService memberSubscriptionPeriodCalculationsService)
 {
     _userRoleMembershipService = userRoleMembershipService;
     _emailService        = emailService;
     _userLookup          = userLookup;
     _memberLookupService = memberLookup;
     _memberRepository    = memberRepository;
     _memberSubscriptionPeriodCalculationsService = memberSubscriptionPeriodCalculationsService;
 }
        public HumanResourceController(ICandidateService candidateService,
                                       UserManager <ApplicationUser> userManager,
                                       ICompositeViewEngine viewEngine,
                                       IUserLookupService userService,
                                       ILookupService lookupService,
                                       IEnrollmentService enrollmentService,
                                       IChecklistService checklistService,
                                       IDatabaseService databaseService) : base(viewEngine)

        {
            this._candidateService  = candidateService;
            this._userManager       = userManager;
            this._userService       = userService;
            this._lookupService     = lookupService;
            this._enrollmentService = enrollmentService;
            this._checklistService  = checklistService;
            this._databaseService   = databaseService;
        }
 public CachingUserLookupService(IUserLookupService userLookupService, IMemoryCache userCache)
 {
     _userLookupService = userLookupService;
     _userCache         = userCache;
 }
Beispiel #10
0
 public MemberSubscriptionRenewalService(IUserLookupService userLookup,
                                         IRepository <Member> memberRepository)
 {
     _userLookup       = userLookup;
     _memberRepository = memberRepository;
 }
 public MemberLookupService(IUserLookupService userLookupService,
                            IRepository <Member> repository)
 {
     _userLookup       = userLookupService;
     _memberRepository = repository;
 }