Esempio n. 1
0
        public async Task<ActionResult> Index(UserViewModel model)
        {
            if (ModelState.IsValid)
            {
                var user = new MyUser() { UserName = model.UserName, EmailAddress = model.Email };
                var result = await UserManager.CreateAsync(user, model.Password);

                if (result.Succeeded)
                {
                    return RedirectToAction("AccountList");
                }
                else
                {
                    AddErrorsFromResult(result);
                }
            }

            return View(model);
        }
Esempio n. 2
0
        public ActionResult UpdateUser(UserViewModel model)
        {

            return new JsonResult();
        }