Exemple #1
0
        public async Task <IActionResult> CreateLogin([FromBody] Login login)
        {
            var newLogin = _mapper.Map <Login>(login);
            await _loginManager.CreateLogin(newLogin);

            return(Ok());
        }
Exemple #2
0
        public void CreateUserWithLogin(string userName, string password)
        {
            var user = _userManager.CreateUser(userName);

            _loginManager.CreateLogin(user, userName, password);
        }