public async Task <IndexHistoryView> GetAllPlayers() { List <Player> players = await _playerRepository.GetAllPlayersByRole(PlayerRole.Player); IndexHistoryView data = new IndexHistoryView(); data.Players = _maping.MapPlayersToPlayerIndexHistoryViewItem(players); return(data); }
public async Task <IndexHistoryView> Index() { IndexHistoryView model = await _historyService.GetAllPlayers(); return(model); }