blob: 9e58fc8d8d5e4aaeeda1323b18c895256df7c5da (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
|
module BlogHelper
def recent_blog_summaries(path)
root = StaticPage.find(path)
if root
pages = root.all_children.order_by(:posted_at, :direction => :desc).limit(PAGINATION_SIZE)
haml do
pages.each do |page|
haml render(:partial => 'layouts/blog/summary', :locals => {:page => page})
end
end
end
end
end
|