Class: Write::PostsController

Inherits:
ApplicationController show all
Includes:
ApplicationHelper
Defined in:
app/controllers/write/posts_controller.rb

Instance Method Summary collapse

Methods included from ApplicationHelper

#atom_feed_url, #head_links, #login_user, #post_snippet, #timestamp_display, #write_admin?

Instance Method Details

#feedObject



25
26
27
# File 'app/controllers/write/posts_controller.rb', line 25

def feed
  @posts = GG.all
end

#indexObject



9
10
11
# File 'app/controllers/write/posts_controller.rb', line 9

def index
  @posts = GG.all
end

#refreshObject



17
18
19
20
21
22
23
# File 'app/controllers/write/posts_controller.rb', line 17

def refresh
  if write_admin?
    GG.clear!
    GG.fetch
  end
  redirect_to :action => :index
end

#showObject



13
14
15
# File 'app/controllers/write/posts_controller.rb', line 13

def show
  @post = GG.find params[:year], params[:code]
end