Пример #1
0
        // GET: Student
        public ActionResult Index()
        {
            if (HttpContext.Session["ID"] != null && !HttpContext.Session["ID"].ToString().Equals(""))
            {
                // db.Students.Find((int)HttpContext.Session["ID"]);

                return(View("index", advertisementDAO.GetAdvsPass()));
            }
            else
            {
                TempData["Message"] = "please login in again ,session is out of time!";
                return(RedirectToAction("Login", "Login"));
            }
        }