summaryrefslogtreecommitdiff
path: root/app/builder
diff options
context:
space:
mode:
authorluxagraf <sng@luxagraf.net>2012-11-22 22:14:34 +0000
committerluxagraf <sng@luxagraf.net>2012-11-22 22:14:34 +0000
commit5ec4e9957220eda531ada80ae2969b3c4cd0bcce (patch)
treec90a5cbf30fde20ceaee287d157301d5c303a556 /app/builder
parent83e49fa3c3ea9b9b3f74b7302df8825aaf4e3d18 (diff)
tweaked Pages template loader to allow for custom templates based on the %s.html %(slug) model.
Diffstat (limited to 'app/builder')
-rw-r--r--app/builder/base.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/app/builder/base.py b/app/builder/base.py
index a112aa0..9dc07e9 100644
--- a/app/builder/base.py
+++ b/app/builder/base.py
@@ -240,7 +240,7 @@ class BuildPages(Build):
pages = model.objects.all()
for page in pages:
c = Context({'object':page,'SITE_URL':settings.SITE_URL, 'MEDIA_URL':settings.BAKED_MEDIA_URL,'IMAGES_URL':settings.BAKED_IMAGES_URL})
- t = render_to_string('details/page.html',c).encode('utf-8')
+ t = render_to_string(["details/%s.html" % page.slug, 'details/page.html'],c).encode('utf-8')
s = render_to_string('details/page.txt',c).encode('utf-8')
fpath = '%s/' %(page.slug)
self.write_file(fpath,t)