Ejemplo n.º 1
0
        public async Task <ActionResult> Create()
        {
            StudentForCreateDto studentForCreateDto = new StudentForCreateDto();

            studentForCreateDto.Fields = await _fieldRepository.GetFields();

            studentForCreateDto.Governorates = await _governateRepostiory.GetGovernorates();

            studentForCreateDto.Neighborhoods = await _neighborhoodRepository.GetNeighborhoods();

            studentForCreateDto.Teachers = await _teacherReposiotry.GetTeachers();

            ViewBag.Teachers = new MultiSelectList(studentForCreateDto.Teachers, "ID", "Name");

            return(View(studentForCreateDto));
        }