예제 #1
0
        public ActionResult Index(User user)
        {
            var dbUser = _userBll.AuthenticateAndGetUserIfOk(user.Username, user.Password);

            if (dbUser != null)
            {
                authenticateUser(dbUser);
                return(RedirectToAction("Index", "Admin"));
            }
            else
            {
                deauthenticateUser();
                return(View());
            }
        }