This commit is contained in:
albert
2011-06-21 12:20:22 -04:00
parent 8a7597bc98
commit 07f8dba7f2
22 changed files with 262 additions and 468 deletions

View File

@@ -1,17 +1,13 @@
require 'pp'
class PostSetPresenter < Presenter
attr_accessor :post_set, :tag_set_presenter
attr_accessor :posts, :tag_set_presenter
def initialize(post_set)
@post_set = post_set
def initialize(posts)
@posts = posts
@tag_set_presenter = TagSetPresenter.new(RelatedTagCalculator.calculate_from_sample_to_array(@post_set.tags).map {|x| x[0]})
end
def posts
post_set.posts
end
def tag_list_html(template)
tag_set_presenter.tag_list_html(template)
end