Added view_about_to_render and view_finished_rendering signals. Added hidden _render_...
[philo.git] / contrib / penfield / models.py
index e433b84..3791e55 100644 (file)
@@ -65,7 +65,8 @@ class BlogView(MultiView, FeedMultiViewMixin):
        entry_permalink_base = models.CharField(max_length=255, blank=False, default='entries')
        tag_permalink_base = models.CharField(max_length=255, blank=False, default='tags')
        feed_suffix = models.CharField(max_length=255, blank=False, default=FeedMultiViewMixin.feed_suffix)
-       feeds_enabled = models.BooleanField() 
+       feeds_enabled = models.BooleanField()
+       list_var = 'entries'
        
        def __unicode__(self):
                return u'BlogView for %s' % self.blog.title
@@ -284,6 +285,7 @@ class NewsletterView(MultiView, FeedMultiViewMixin):
        
        feed_suffix = models.CharField(max_length=255, blank=False, default=FeedMultiViewMixin.feed_suffix)
        feeds_enabled = models.BooleanField()
+       list_var = 'articles'
        
        @property
        def feed_title(self):
@@ -386,9 +388,9 @@ class NewsletterView(MultiView, FeedMultiViewMixin):
                        article = articles.get(slug=slug)
                except:
                        raise Http404
-               context = {}
+               context = self.get_context()
                context.update(extra_context or {})
-               context.update({'newsletter': self.newsletter, 'article': article})
+               context.update({'article': article})
                return self.article_page.render_to_response(node, request, extra_context=context)
        
        def issue_archive_view(self, request, node=None, extra_context=None):