Exemplo n.º 1
0
 public Task <List <Coach> > GetCoaches()
 {
     try
     {
         return(_coachRepository.GetAll());
     }
     catch (Exception ex)
     {
         _logger.LogWarning($"{ex.Message}\r\n{ex.StackTrace}");
         return(null);
     }
 }
Exemplo n.º 2
0
        public List <Coach> GetAllCoaches()
        {
            var dbcoaches = _coachRepo.GetAll();

            List <Coach> coaches = new List <Coach>();

            foreach (COACH dbcoach in dbcoaches)
            {
                coaches.Add(new Coach(dbcoach.COACH_INTERNAL_ID, dbcoach.PERSON.FIRSTNAME, dbcoach.PERSON.LASTNAME, dbcoach.PERSON.EMAIL,
                                      dbcoach.PERSON.TELEPHONE, dbcoach.PAYOFFRATE, dbcoach.PAYMENTRATE, (Decimal)dbcoach.PAYOFF));
            }

            return(coaches);
        }
Exemplo n.º 3
0
 public List <CoachDto> GetAll()
 {
     return(_coachRepository.GetAll().Select(c => _mapper.Map <CoachDto>(c)).ToList());
 }
Exemplo n.º 4
0
 public async Task <List <Coach> > GetAllCoaches()
 {
     return(await _coachRepo.GetAll());
 }
 public List <Coach> GetAll()
 {
     return(_repository.GetAll());
 }
Exemplo n.º 6
0
 public async Task <List <Coach> > GetCoachs()
 {
     return(await _Coachs.GetAll());
 }