Class: MostDiscussedCell

Inherits:
BaseCell
  • Object
show all
Defined in:
app/cells/most_discussed_cell.rb

Constant Summary collapse

LIMIT =
9

Instance Method Summary collapse

Methods included from PostsHelper

#permalink_url, #post_description_short, #post_descritpion_has_image?, #post_teaser_for, #smart_post_path, #smart_post_url, #text_short, #typography

Methods included from CommentsHelper

#comment_path, #comment_url, #comments_link

Methods included from ApplicationHelper

#benchmark, #bootstrap_class_for, #counter_tag, #format_date, #glyphicon, #js_redirect_to, #recaptcha_tags, #send_ga_events, #smart_date, #snippet, #time_or_date

Instance Method Details

#horizontalObject


9
10
11
12
# File 'app/cells/most_discussed_cell.rb', line 9

def horizontal
  @posts = most_discussed_posts.limit(6)
  render
end

#showObject


4
5
6
7
# File 'app/cells/most_discussed_cell.rb', line 4

def show
  @posts = most_discussed_posts
  cell('posts/text_block', @posts)
end