Class: JournalCategoriesController

Inherits:
ApplicationController
  • Object
show all
Defined in:
app/controllers/journal_categories_controller.rb

Instance Method Summary collapse

Instance Method Details

#previewObject



10
11
12
13
14
# File 'app/controllers/journal_categories_controller.rb', line 10

def preview
  @category = JournalCategory.find(@slug)
  @posts = posts
  render @category.template_name || "show"
end

#showObject



4
5
6
7
8
# File 'app/controllers/journal_categories_controller.rb', line 4

def show
  @category = JournalCategory.not_hidden.find(@slug)
  @posts = posts
  render @category.template_name || "show"
end