+
+
+def publish_plan(request):
+ cache_key = "publish_plan"
+ plan = cache.get(cache_key)
+
+ if plan is None:
+ plan = []
+ try:
+ feed = feedparser.parse(settings.PUBLISH_PLAN_FEED)
+ except:
+ pass
+ else:
+ for i in range(len(feed['entries'])):
+ plan.append({
+ 'title': feed['entries'][i].title,
+ 'link': feed['entries'][i].link,
+ })
+ cache.set(cache_key, plan, 1800)
+
+ return render_to_response("publish_plan.html", {'plan': plan},
+ context_instance=RequestContext(request))
+
+
+@login_required
+def user_settings(request):
+ return render_to_response("user.html",
+ context_instance=RequestContext(request))