public void Post([FromBody] UserModel user) { //var tokenHandler = new JwtSecurityTokenHandler(); //var _tokenManager = new JwtManager(); //HttpResponseMessage response; _userModel.Create(user); //create token //string token = _tokenManager.GenerateToken(user.Name); }
public ActionResult Create(CreateEditUserViewModel user) { user.UserDetails.Roles = _userModel.GetRoles(user.SelectedRoles).ToList(); if (!ModelState.IsValid) { return(View(user)); } _userModel.Create(user.UserDetails); return(RedirectToAction("Index")); }