public ActionResult Index()
        {
            var cons  = StudentService.GetAllConsultations();
            var studs = StudentService.GetAll();
            var lecs  = LectorService.GetAll();

            ViewBag.Students      = studs;
            ViewBag.Lectors       = lecs;
            ViewBag.Consultations = cons;
            return(View());
        }
Beispiel #2
0
        public async Task <IActionResult> GetAll()
        {
            var result = await _lectorService.GetAll();

            if (result == null)
            {
                return(NotFound());
            }

            var lectors = _mapper.Map <IEnumerable <LectorResponse> >(result);

            return(Ok(lectors));
        }