public ActionResult CreateAccount(UserViewModel user)
        {
            var converted = UserViewModel.ConvertUserViewModelToModel(user);
            var check     = userlogic.CheckDoubleEmails(converted);

            if (check == true)
            {
                TempData["DoubleEmails"] = "The specified email is already known in our system.";
                return(View());
            }
            else
            {
                _user.Create(converted);
            }
            return(RedirectToAction("Index"));
        }
예제 #2
0
 public ActionResult Update(UserViewModel model)
 {
     _user.Edit(UserViewModel.ConvertUserViewModelToModel(model));
     TempData["Update"] = "The records has been changed from the system!";
     return(RedirectToAction("Index"));
 }