League Information
This commit is contained in:
@@ -1,4 +1,4 @@
|
|||||||
function redirectToLeaguePage(leagueName) {
|
function redirectToLeaguePage(leagueName, leagueID) {
|
||||||
// Append the league name to the URL
|
// Append the league name to the URL
|
||||||
var url = "/league/" + leagueName.toLowerCase().replace(/\s+/g, '-');
|
var url = "/league/" + leagueName.toLowerCase().replace(/\s+/g, '-');
|
||||||
|
|
||||||
|
|||||||
@@ -30,12 +30,14 @@ const fetchleagueesData = async (req, res, next) => {
|
|||||||
table: {
|
table: {
|
||||||
league_position: league.standings.table.position,
|
league_position: league.standings.table.position,
|
||||||
team_id: league.standings.table.team.id,
|
team_id: league.standings.table.team.id,
|
||||||
|
team_name: league.standings.table.team.name,
|
||||||
|
team_crest: league.standings.table.team.crest
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}));
|
}));
|
||||||
|
|
||||||
// Concatenate leaguees data to allleaguees array
|
// Concatenate leaguees data to allleaguees array
|
||||||
allLeaguees = allLeaguees.concat(leagues);
|
allLeagues = allLeagues.concat(leagues);
|
||||||
}
|
}
|
||||||
|
|
||||||
// Attach all leaguees data to res.locals
|
// Attach all leaguees data to res.locals
|
||||||
|
|||||||
@@ -10,9 +10,7 @@
|
|||||||
|
|
||||||
<!-- Container to display league table <- split 50% -->
|
<!-- Container to display league table <- split 50% -->
|
||||||
<div class="container" id="league-table-container">
|
<div class="container" id="league-table-container">
|
||||||
{{#each league}}
|
|
||||||
{{> navigation-bar/scoreboard-header/game-card}}
|
|
||||||
{{/each}}
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user