Esempio n. 1
0
        public virtual async Task AddUser(AddUserInput input)
        {
            Ensure.NotNull(input, nameof(input));
            var user = User.Create(input.UserAccount, input.UserName, input.Password, input.Email,
                                   input.CellPhone,
                                   input.Description);

            using (var work = CurrentUnitOfWork.SetTenantId(input.TenantId))
            {
                _userRepository.Insert(user);

                await CurrentUnitOfWork.CommitAsync();
            }
        }