Exemplo n.º 1
0
        public ActionResult ExamResult()
        {
            //BasExamContext context = new BasExamContext();
            ExamVM Exvm = new ExamVM();

            //List<Exam> Examliste = context.Exams.ToList();
            //Exvm.Examlist = Examliste;
            Exvm.ClassList = cRepo.GetAll().Select(x => new SelectListItem
            {
                Text  = x.Name,
                Value = x.Id.ToString()
            }).ToList();
            Exvm.SectionList = sectionrepo.GetAll().Select(x => new SelectListItem
            {
                Text  = x.Name,
                Value = x.Id.ToString()
            }).ToList();
            return(View(Exvm));
        }
Exemplo n.º 2
0
 public ActionResult Add()
 {
     TempData["classroom"] = clsRepo.GetAll();
     TempData["section"]   = sRepo.GetAll();
     return(View());
 }
 private void RefreshList()
 {
     SectionsList = SectionRepo.GetAll();
 }