public AuthentificationHttpService(IKernel kernel)
 {
     this.kernel             = kernel;
     this.identity           = kernel.Get <IUnitOfWorkIdentity>();
     this.UserRepository     = kernel.Get <IRepository <User, string> >();
     this.EmployeeRepository = kernel.Get <IRepository <Employee, string> >();
 }
Beispiel #2
0
 public AccountController(IAccount account,
                          IUnitOfWorkIdentity unitOfWork
                          )
 {
     _account    = account;
     _unitOfWork = unitOfWork;
 }
Beispiel #3
0
 /// <summary>
 /// 依赖注入构造器
 /// </summary>
 /// <param name="svcMediator">领域服务中介者</param>
 /// <param name="repMediator">仓储中介者</param>
 /// <param name="unitOfWork">单元事务</param>
 public AuthorityCreatedEventHandler(DomainServiceMediator svcMediator, RepositoryMediator repMediator, IUnitOfWorkIdentity unitOfWork)
 {
     this._svcMediator = svcMediator;
     this._repMediator = repMediator;
     this._unitOfWork  = unitOfWork;
     this.Sort         = uint.MaxValue;
 }
Beispiel #4
0
 public CourseController(ICourse course,
                         IUnitOfWorkIdentity unitOfWork,
                         IOptions <ApplicationSettings> extendedOptions)
 {
     _course          = course;
     _unitOfWork      = unitOfWork;
     _extendedOptions = extendedOptions;
 }
 public AccountController(IUserAppService userSvc,ILogWriterSql log, ICookieConsumer storage, IAccountService account, IUnitOfWorkIdentity unit, IClearUserSession userSession)
     : base(storage)
 {
     _userSvc = userSvc;
     _unit = unit;
     _log = log;
     _account = account;
     _userSession = userSession;
 }
Beispiel #6
0
 /// <summary>
 /// 依赖注入构造器
 /// </summary>
 /// <param name="repMediator">仓储中介者</param>
 /// <param name="unitOfWork">单元事务</param>
 public DataInitializer(RepositoryMediator repMediator, IUnitOfWorkIdentity unitOfWork)
 {
     this._repMediator = repMediator;
     this._unitOfWork  = unitOfWork;
     this._systems     = new List <InfoSystem>();
     this._users       = new List <User>();
     this._roles       = new List <Role>();
     this._menus       = new List <Menu>();
 }
Beispiel #7
0
        public UserStore(IUnitOfWorkIdentity unitOfWork)
        {
            if (unitOfWork == null)
            {
                throw new ArgumentNullException("unitOfWork");
            }

            ShouldDisposeSession = true;
            this.unitOfWork      = (UnitOfWorkIdentity)unitOfWork;
        }
Beispiel #8
0
 public UserService(IRepository <User, string> repository,
                    IUnitOfWorkIdentity identity,
                    IServiceT <User, UserDTO, string> service,
                    IAddressService addressService)
 {
     this.repository     = repository;
     this.identity       = identity;
     this.service        = service;
     this.AddressService = addressService;
 }
Beispiel #9
0
        /// <summary>
        /// Creates service
        /// </summary>
        /// <param name="uowi">Identity UnitOfWork</param>
        /// <param name="uow">UnitOfWork</param>
        /// <exception cref="ArgumentNullException"/>
        public UserManager(IUnitOfWorkIdentity uowi, IUnitOfWork uow)
        {
            if (uow == null || uowi == null)
            {
                throw new ArgumentNullException();
            }

            DatabaseIdentity = uowi;
            DatabaseDomain   = uow;
        }
Beispiel #10
0
 public Account(IAccountRepository accountRepository,
                IUserRepository userRepository,
                IPasswordRecovery passwordRecovery,
                IEmailService emailService,
                IUnitOfWorkIdentity unitOfWorkIdentity)
 {
     _accountRepository  = accountRepository;
     _passwordRecovery   = passwordRecovery;
     _emailService       = emailService;
     _userRepository     = userRepository;
     _unitOfWorkIdentity = unitOfWorkIdentity;
 }
Beispiel #11
0
 public ServiceT(IRepository <TEntity, TType> repo, IUnitOfWorkIdentity identity, IKernel kernel)
 {
     repository    = repo;
     this.identity = identity;
     this.kernel   = kernel;
     //Mapper.Initialize(cfg =>
     //{
     //    cfg.CreateMap<TEntity, TEntityDto>();
     //    cfg.CreateMap<TEntityDto, TEntity>();
     //});
     //Mapper.Initialize(cfg => cfg.CreateMap<TEntity, TEntityDto>());
     //Mapper.Initialize(cfg => cfg.CreateMap<TEntityDto, TEntity>());
 }
Beispiel #12
0
 /// <summary>
 /// 依赖注入构造器
 /// </summary>
 /// <param name="repMediator">仓储中介者</param>
 /// <param name="unitOfWork">单元事务</param>
 public AuthenticationContract(RepositoryMediator repMediator, IUnitOfWorkIdentity unitOfWork)
 {
     this._repMediator = repMediator;
     this._unitOfWork  = unitOfWork;
 }
 public AuthentificationWPFService(IKernel kernel)
 {
     this.kernel   = kernel;
     this.identity = kernel.Get <IUnitOfWorkIdentity>();
 }
Beispiel #14
0
 public UserService(IUnitOfWork uow, IUnitOfWorkIdentity uowi)
 {
     database         = uow;
     databaseIdentity = uowi;
 }
 /// <summary>
 /// 依赖注入构造器
 /// </summary>
 /// <param name="unitOfWork">单元事务</param>
 public InfoSystemCreatedEventHandler(IUnitOfWorkIdentity unitOfWork)
 {
     this._unitOfWork = unitOfWork;
     this.Sort        = uint.MaxValue;
 }
 public ClientProfileService(IUnitOfWorkIdentity ui, IUnitOfWork u)
 {
     db         = u;
     dbIdentity = ui;
 }
Beispiel #17
0
 public UserService(IUnitOfWorkIdentity uow)
 {
     Database = uow;
 }
 /// <summary>
 /// 依赖注入构造器
 /// </summary>
 /// <param name="svcMediator">领域服务中介者</param>
 /// <param name="repMediator">仓储中介者</param>
 /// <param name="unitOfWork">单元事务</param>
 public AuthorizationContract(DomainServiceMediator svcMediator, RepositoryMediator repMediator, IUnitOfWorkIdentity unitOfWork)
 {
     this._svcMediator = svcMediator;
     this._repMediator = repMediator;
     this._unitOfWork  = unitOfWork;
 }
 /// <summary>
 /// 依赖注入构造器
 /// </summary>
 /// <param name="repMediator">仓储中介者</param>
 /// <param name="unitOfWork">单元事务</param>
 public UserContract(RepositoryMediator repMediator, IUnitOfWorkIdentity unitOfWork)
 {
     this._repMediator = repMediator;
     this._unitOfWork  = unitOfWork;
 }
Beispiel #20
0
 public UserService(IUnitOfWorkIdentity uowi, IUnitOfWork uow)
 {
     DatabaseUsers = uowi;
     Database      = uow;
 }
Beispiel #21
0
 public UserService(IUnitOfWorkIdentity unitOfWork)
 {
     Database = unitOfWork;
 }
 public ClientApplicationManager(IUnitOfWorkIdentity uow, ILogger <ClientApplicationManager> logger, IMapper mapper, IHttpContextAccessor httpContextAccessor) : base(logger, mapper, httpContextAccessor)
 {
     _uow = uow;
 }
Beispiel #23
0
 public AccountService(IUnitOfWorkIdentity unitOfWorkIdentity)
 {
     DatabaseIdentity = unitOfWorkIdentity;
 }