Exemplo n.º 1
0
        public List <PlayerItemViewModel> GetDeletedPlayers()
        {
            List <PlayerItemViewModel> playersToReturn = _repo.GetDeletedPlayers()
                                                         .Select(player =>
            {
                string team = _teamRepo.GetTeam(player.TeamId).Name;
                return(ModelFactory.CreateViewModel(player, team, player.Deleted_Date));
            })
                                                         .ToList();

            return(playersToReturn);
        }