Beispiel #1
0
        // GET: Supervisors
        public async Task <IActionResult> Index()
        {
            var supervisors = await _supervisorRepository.GetAll();

            var supervisorIndexViewModel = new List <SupervisorIndexViewModel>();

            foreach (var supervisor in supervisors)
            {
                supervisorIndexViewModel.Add(_mapper.Map <SupervisorIndexViewModel>(supervisor));
            }


            return(View(supervisorIndexViewModel));
        }
 public async Task <IEnumerable <SupervisorVM> > GetSupervisors()
 {
     return(await _supervisorRepository.GetAll());
 }
 public List <Supervisor> GetAll()
 {
     return(repo.GetAll());
 }