[SCM] live-studio branch, master, updated. be51da814fb12d25dce46a7f078a46f5c89bd777

Chris Lamb lamby at debian.org
Fri Jul 30 02:52:33 UTC 2010


The following commit has been merged in the master branch:
commit 1cfb2a08bb4468075afe930a3dd693f2e60d25d1
Author: Chris Lamb <lamby at debian.org>
Date:   Wed Jul 28 17:31:50 2010 -0400

    Add render_response helper that does RequestContext stuff for us.
    
    Signed-off-by: Chris Lamb <lamby at debian.org>

diff --git a/live_studio_www/utils/__init__.py b/live_studio_www/utils/__init__.py
index e69de29..068da6a 100644
--- a/live_studio_www/utils/__init__.py
+++ b/live_studio_www/utils/__init__.py
@@ -0,0 +1 @@
+from rendering import *
diff --git a/live_studio_www/utils/rendering.py b/live_studio_www/utils/rendering.py
new file mode 100644
index 0000000..7ec0f13
--- /dev/null
+++ b/live_studio_www/utils/rendering.py
@@ -0,0 +1,10 @@
+from django.template import RequestContext
+from django.shortcuts import render_to_response
+
+def render_response(request, template, context=None, mimetype='text/html'):
+    return render_to_response(
+        template,
+        context or {},
+        context_instance=RequestContext(request),
+        mimetype=mimetype,
+    )

-- 
live-studio



More information about the debian-live-changes mailing list