public IActionResult GetFormEducation()
        {
            FormEducationModel newModel = new FormEducationModel();

            newModel.newList = formEducation.GetAll().ToList();
            return(View("~/Views/AdminDepartment/FormEducation/FormEducation.cshtml", newModel));
        }
Ejemplo n.º 2
0
        //public IActionResult GetGruppa()
        //{
        //    Gruppa gruppa = new Gruppa();
        //}

        public IActionResult AddGruppa()
        {
            AddGruppa model = new AddGruppa();

            model.newList = educDegree.GetAll().Select(p => new SelectListItem {
                Value = p.EducationalDegreeName, Text = p.EducationalDegreeName
            }).ToList();
            model.newListCathedra = cathedra.GetAll().Select(p => new SelectListItem {
                Value = p.cathedraName, Text = p.cathedraName
            }).ToList();
            //model.newListCurator = curator.GetAll().Select(p => new SelectListItem { Value, Text = p.cathedraNameDTO }).ToList();
            //model.newListStarosta = starosta.GetAll().Select(p => new SelectListItem { Value = p.cathedraNameDTO, Text = p.cathedraNameDTO }).ToList();
            model.newListEducation = educFormService.GetAll().Select(p => new SelectListItem {
                Value = p.FormEducationName, Text = p.FormEducationName
            }).ToList();
            return(View("~/Views/StudentDepartment/Gruppa/AddGruppa.cshtml", model));
        }
        //public IActionResult GetCurriculum()
        //{
        //    CurriculumsModel newModel = new CurriculumsModel();
        //    newModel.newList = _Service.GetAll().ToList();
        //    return View("~/Views/Curriculum/Curriculums.cshtml", newModel);
        //}

        //public async Task<IActionResult> AddNewCurriculum(AddCurriculumModel model)
        //{
        //    CurriculumDTO newItem = new CurriculumDTO()
        //    {
        //        Qualification = model.Qualification,
        //        NameSpecialization = model.nameSpecialization,
        //        NameEducationalDegree = model.nameEducationalDegree,
        //        NameForm_of_education = model.nameForm_of_education,
        //        TrainingPeriod = model.TrainingPeriod,
        //        BasedOn = model.BasedOn
        //    };

        //    await curriculum.Create(newItem);
        //    return RedirectToAction("VHome", "CurriculumDepartment");
        //}

        public IActionResult GetAddCurriculum()
        {
            AddCurriculumModel newModel = new AddCurriculumModel();

            newModel.newListSpecialization = specialization.GetAll().ToList().Select(x => new SelectListItem {
                Text = x.nameSpecialization, Value = x.nameSpecialization
            }).ToList();
            newModel.newListForm_of_education = formEducation.GetAll().ToList().Select(x => new SelectListItem {
                Text = x.FormEducationName, Value = x.FormEducationName
            }).ToList();
            newModel.newListEducationalDegree = educationalDegree.GetAll().ToList().Select(x => new SelectListItem {
                Text = x.EducationalDegreeName, Value = x.EducationalDegreeName
            }).ToList();
            newModel.newKnowledgeArea = knowledgeArea.GetAll().ToList().Select(x => new SelectListItem {
                Text = x.areaCode + "  " + x.areaName, Value = x.areaName
            }).ToList();
            newModel.newFaculty = faculty.GetAll().ToList().Select(x => new SelectListItem {
                Text = x.facultyName, Value = x.facultyName
            }).ToList();



            return(View("~/Views/CurriculumDepartment/Curriculum/AddCurriculum.cshtml", newModel));
        }