public ActionResult ResetAuthPassword(string password, int userid)
        {
            var mgr  = new UserAuthRepository();
            var rmgr = new ResetPasswordRepository();

            mgr.AddAction(userid, "reset password", DateTime.Now);
            rmgr.DeleteToken(userid);
            mgr.UpdatePassword(password, userid);
            return(RedirectToAction("Login"));
        }
        public ActionResult Login(string email, string password)
        {
            var  mgr = new UserAuthRepository();
            User u   = mgr.GetUser(email, password);

            if (u == null)
            {
                return(View(true));
            }
            else
            {
                mgr.AddAction(u.Id, "Log In", DateTime.Now);
                FormsAuthentication.SetAuthCookie(u.Id.ToString(), true);
                return(RedirectToAction("index", "portal"));
            }
        }