View errors cleaned up

This commit is contained in:
pydanny 2010-06-18 18:10:51 -05:00
parent af5eca727a
commit 0b854bc834
3 changed files with 8 additions and 3 deletions

View file

@ -1,3 +1,3 @@
<h2>Terms of Service as of {{ tos.created|date:"SHORT_DATE_FORMAT }}</h2>
<h2>Terms of Service as of {{ tos.created|date:"SHORT_DATE_FORMAT" }}</h2>
{{ tos.content }}

View file

@ -1,7 +1,7 @@
{% if note %}
<h2>{{ note }}</note>
{% else %}
<h2>Terms of Service as of {{ tos.created|date:"SHORT_DATE_FORMAT }}</h2>
<h2>Terms of Service as of {{ tos.created|date:"SHORT_DATE_FORMAT" }}</h2>
{% endif %}
{{ tos.content }}

View file

@ -1,6 +1,7 @@
from django.conf.urls.defaults import *
from django.views.generic.simple import direct_to_template
from tos.models import TermsOfService
from tos.views import check_tos
urlpatterns = patterns('',
@ -15,7 +16,11 @@ urlpatterns = patterns('',
url(
regex = '^$',
view = direct_to_template,
kwargs = {'template': 'tos/tos.html'},
kwargs = {'template': 'tos/tos.html',
'extra_context':{
'tos':TermsOfService.objects.get_current_tos()
},
},
name = 'tos',
),
)