Skip to content

Commit

Permalink
Add live score routes
Browse files Browse the repository at this point in the history
  • Loading branch information
johnwatson484 committed Jul 30, 2022
1 parent 0d11159 commit b46d338
Show file tree
Hide file tree
Showing 5 changed files with 20 additions and 1 deletion.
1 change: 1 addition & 0 deletions app/plugins/router.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ const routes = [].concat(
require('../routes/fixtures'),
require('../routes/groups'),
require('../routes/history'),
require('../routes/live-scores'),
require('../routes/api/winners'),
require('../routes/api/meetings'),
require('../routes/public')
Expand Down
10 changes: 10 additions & 0 deletions app/routes/live-scores.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@

module.exports = [{
method: 'GET',
path: '/live-scores',
options: {
handler: async (_request, h) => {
return h.view('live-scores')
}
}
}]
3 changes: 3 additions & 0 deletions app/views/_layout.njk
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@
</button>
<div class="navbar-collapse collapse d-sm-inline-flex">
<ul class="navbar-nav flex-grow-1">
<li class="nav-item">
<a class="nav-link text-light" href="/live-scores">Live scores</a>
</li>
{% if auth.isAdmin %}
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle text-light" href="#" id="navbarDropdown" role="button"
Expand Down
5 changes: 5 additions & 0 deletions app/views/live-scores.njk
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
{% extends '_layout.njk' %}

{% block content %}
<h2>Coming soon...</h2>
{% endblock %}
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "dream-league-web",
"version": "1.3.13",
"version": "1.3.14",
"description": "Dream League web frontend",
"main": "app/index.js",
"scripts": {
Expand Down

0 comments on commit b46d338

Please sign in to comment.