From b6a18c43aee27f60c3cade44a774202ad23f0c33 Mon Sep 17 00:00:00 2001 From: ale <ale@incal.net> Date: Fri, 28 Oct 2011 09:58:28 +0100 Subject: [PATCH] get the site name from the app config --- server/djrandom/frontend/templates/about.html | 2 +- server/djrandom/frontend/templates/index.html | 12 +++++------- server/djrandom/frontend/views.py | 4 ++-- 3 files changed, 8 insertions(+), 10 deletions(-) diff --git a/server/djrandom/frontend/templates/about.html b/server/djrandom/frontend/templates/about.html index df3049d..ec50e01 100644 --- a/server/djrandom/frontend/templates/about.html +++ b/server/djrandom/frontend/templates/about.html @@ -2,7 +2,7 @@ {% block title %}About{% endblock %} {% block main %} - <h3>DJ:Random</h3> + <h3>{{ config['SITE_NAME'] }}</h3> <p> <b>{{ num_users }}</b> users, diff --git a/server/djrandom/frontend/templates/index.html b/server/djrandom/frontend/templates/index.html index da1780d..7daa403 100644 --- a/server/djrandom/frontend/templates/index.html +++ b/server/djrandom/frontend/templates/index.html @@ -10,7 +10,7 @@ $(document).ready(function() { {% endblock %} {% block title %} -DJ:Random +{{ config['SITE_NAME'] }} {% endblock %} {% block body %} @@ -87,16 +87,14 @@ DJ:Random | <a id="playlistNever5">Never 5</a> <a id="playlistNever25">(25)</a> | <a id="playlistSave">Save as</a><div id="saveForm" style="display:none;" > <input type="text" name="s" size="15" id="savetext" ><a id="playlistSaveBtn" >Save</a></div> - </div> - <div id="playlistDiv"> - </div> - - <div id="playlistControls" class="buttonbox"> - <a id="playlistExtendBtn">Extend</a> + | <a id="playlistExtendBtn">Extend</a> | <a id="playlistClearBtn">Clear</a> | <a id="playlistStreamBtn">Stream</a> <span id="playlistStreamUrl"></span> </div> + <div id="playlistDiv"> + </div> + </div> <img id="albumart_fs" style="display:none;"> diff --git a/server/djrandom/frontend/views.py b/server/djrandom/frontend/views.py index 0811208..6edcd5a 100644 --- a/server/djrandom/frontend/views.py +++ b/server/djrandom/frontend/views.py @@ -51,14 +51,14 @@ def about(): num_users = User.query.filter_by(active=True).count() return render_template('about.html', num_users=num_users, num_songs=num_songs, used_gb=used_gb, - dup_songs=dup_songs) + dup_songs=dup_songs, config=app.config) @app.route('/') @require_auth def homepage(): user = User.query.get(g.userid) - return render_template('index.html', user=user) + return render_template('index.html', user=user, config=app.config) @app.route('/ext') -- GitLab