Esempio n. 1
0
 public ActionResult Exam()
 {
     int sid = getSid();
     if (sid == -1)
     {
         return Redirect("/Index/Index");
     }
     ExamModel model = new ExamModel();
     ViewBag.data = model.getAvailableExam();
     assignTitle();
     return View();
 }
Esempio n. 2
0
        public ActionResult Index()
        {
            int sid = getSid();
            if (sid == -1)
            {
                return Redirect("/Index/Index");
            }
            AnnouncementModel announceModel = new AnnouncementModel();
            ExamModel examModel = new ExamModel();
            FileModel fileModel = new FileModel();

            ViewBag.announcement = announceModel.getAnnouncements(0, 3);
            ViewBag.exam = examModel.getAvailableExam().Take(3);
            ViewBag.file = fileModel.getFiles(0, 3);
            assignTitle();
            return View();
        }