mirror of
https://github.com/pinry/pinry.git
synced 2025-11-13 00:25:41 +01:00
Allow for some branding.
This commit is contained in:
7
pinry/core/context_processors.py
Normal file
7
pinry/core/context_processors.py
Normal file
@@ -0,0 +1,7 @@
|
||||
from django.conf import settings
|
||||
|
||||
|
||||
def template_settings(request):
|
||||
return {
|
||||
'site_name': settings.SITE_NAME,
|
||||
}
|
||||
@@ -3,7 +3,7 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>Pinry - {% block title %}{% endblock %}</title>
|
||||
<title>{{ site_name }} - {% block title %}{% endblock %}</title>
|
||||
|
||||
{% if debug %}
|
||||
<link rel="stylesheet" href="/static/vendor/bootstrap/2.0.3/css/bootstrap.css">
|
||||
@@ -20,7 +20,7 @@
|
||||
<body>
|
||||
<div class="navbar navbar-fixed-top">
|
||||
<div class="navbar-inner">
|
||||
<a href="{% url core:home %}" class="brand">Pinry</a>
|
||||
<a href="{% url core:home %}" class="brand">{{ site_name }}</a>
|
||||
|
||||
<ul class="nav pull-right">
|
||||
{% if user.is_authenticated %}
|
||||
|
||||
@@ -2,6 +2,9 @@ import os
|
||||
from django.contrib.messages import constants as messages
|
||||
|
||||
|
||||
SITE_NAME = 'Pinry'
|
||||
|
||||
|
||||
SITE_ROOT = os.path.join(os.path.realpath(os.path.dirname(__file__)), '../../')
|
||||
|
||||
|
||||
@@ -39,6 +42,7 @@ TEMPLATE_CONTEXT_PROCESSORS = (
|
||||
"django.core.context_processors.static",
|
||||
"django.core.context_processors.request",
|
||||
"django.contrib.messages.context_processors.messages",
|
||||
"pinry.core.context_processors.template_settings",
|
||||
)
|
||||
|
||||
ROOT_URLCONF = 'pinry.urls'
|
||||
|
||||
Reference in New Issue
Block a user