Ejemplo n.º 1
0
        public async Task <ActionResult> InstructorIndex()
        {
            Instructor        instructor = null;
            List <Instructor> res        = new List <Instructor>();

            using (_instructorRepository = new InstructorRepository())
            {
                ViewBag.Enrollments = await _instructorRepository.GetInstructorEnrollmentsAsync(HttpContext.User.Identity.GetUserId());

                instructor = await _instructorRepository.GetAsync(HttpContext.User.Identity.GetUserId());
            }
            return(View(instructor));
        }