Ejemplo n.º 1
0
        public ActionResult Result(int id = 1)
        {
            if (!Permission.LoginedNeed(Request, Response, Session))
            {
                return(Json(false));
            }

            Pager <Result> pager = new Pager <Result>();

            User user = (User)Session["user"];
            IOrderedQueryable <Result> results = ResultView.GetResultByUid(user.uid);

            ViewBag.page       = id;
            ViewBag.results    = pager.GetPage(results, id);
            ViewBag.pageNumber = pager.GetPageNumber(results);

            return(View());
        }