Added leaderboard vars...
This commit is contained in:
parent
823f035a45
commit
9bf4326918
|
@ -23,7 +23,9 @@ routes.get(
|
||||||
'/maps/:map',
|
'/maps/:map',
|
||||||
(req, res) => {
|
(req, res) => {
|
||||||
const map = wrapper.map(req.params.map)
|
const map = wrapper.map(req.params.map)
|
||||||
tx(req, res)('pages/mapSingle.njk', { map }, { currentSection: "maps" })
|
const raceLeaderboard = wrapper.leaderboardRace(req.params.map, 1, 10)
|
||||||
|
const teamLeaderboard = wrapper.leaderboardTeamrace(req.params.map, 1, 10)
|
||||||
|
tx(req, res)('pages/mapSingle.njk', { map, raceLeaderboard, teamLeaderboard }, { currentSection: "maps" })
|
||||||
}
|
}
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
|
@ -1,6 +1,8 @@
|
||||||
{% extends "../templates/basic.njk" %}
|
{% extends "../templates/basic.njk" %}
|
||||||
{% import "../components/_map.njk" as mapComponent %}
|
{% import "../components/_map.njk" as mapComponent %}
|
||||||
{% set map = data.map %}
|
{% set map = data.map %}
|
||||||
|
{% set raceLeaderboard = data.raceLeaderboard %}
|
||||||
|
{% set teamLeaderboard = data.teamLeaderboard %}
|
||||||
|
|
||||||
{% block head %}
|
{% block head %}
|
||||||
<title>DDStats - Maps!</title>
|
<title>DDStats - Maps!</title>
|
||||||
|
|
Loading…
Reference in New Issue
Block a user