public AppAuthService(IEntityService <UserAccount> entityService, IEntityService <RealEstate> estateEntityService, IOptions <AuthSetting> authOptions,
                       IOptions <AppSetting> appOptions, IPasswordService passwordService, IFastHasher hasher, IUserGroupProvider groupProvider)
 {
     _entityService       = entityService;
     _estateEntityService = estateEntityService;
     _passwordService     = passwordService;
     _hasher        = hasher;
     _groupProvider = groupProvider;
     _authSetting   = authOptions.Value;
     _appSetting    = appOptions.Value;
 }
예제 #2
0
        public UserAccountController(IModelService <UserAccount, UserAccountDto> modelService,
                                     IUserProvider userProvider, IUserGroupProvider groupProvider, IFastHasher fastHasher, IUploadHelperService uploadHelperService, IPathProvider pathProvider) : base(modelService)
        {
            _userProvider        = userProvider;
            _uploadHelperService = uploadHelperService;
            _pathProvider        = pathProvider;
            _fastHasher          = fastHasher;
            _groupProvider       = groupProvider;
            var administratorGroupId = groupProvider[UserGroup.Administrator].Id;

            modelService.SetBaseFilter(i => i.Where(u => u.IsActive == true && u.UserAccountGroup.FirstOrDefault(g => g.UserAccountId == u.Id).UserGroupId
                                                    != administratorGroupId));
        }
 public AuthController(IAppAuthService appAuthService, IEntityService <UserAccount> userService
                       , IModelService <UserAccount, UserAccountDto> userAccount
                       , IUserProvider userProvider, IMailer mailer, IOptions <AppSetting> appSetting
                       , IUserGroupProvider groupProvider, IEntityService <RealEstate> estateService
                       , IRecaptchaService recaptchaService
                       , IPasswordService passwordService)
 {
     _appAuthService   = appAuthService;
     _userAccount      = userAccount;
     _userProvider     = userProvider;
     _mailer           = mailer;
     _groupProvider    = groupProvider;
     _estateService    = estateService;
     _recaptchaService = recaptchaService;
     _appSetting       = appSetting.Value;
     _userService      = userService;
     _passwordService  = passwordService;
 }
예제 #4
0
 public UserGroupController(IUserGroupProvider provider)
 {
     this.provider = provider;
 }
예제 #5
0
 public InitializeDbStartupFilter(IServiceProvider serviceProvider,
                                  // warm ups
                                  IUserGroupProvider groupProvider)
 => _serviceProvider = serviceProvider;
예제 #6
0
 public UserGroupController(IUserGroupProvider provider)
 {
     this.provider = provider;
 }