Class: AboutPage::AboutController

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

Instance Method Summary collapse

Instance Method Details

#indexObject



7
8
9
10
11
12
13
14
15
16
17
18
# File 'app/controllers/about_page/about_controller.rb', line 7

def index
  @configuration = AboutPage.configuration

  @configuration = @configuration.select { |key, value| (params[:filter].split(/[\W\+]/) + ["app"]).include? key.to_s } if params[:filter]
  @configuration.set_headers!(response)

  respond_to do |format|
    format.html { render :status => @configuration.valid? ? 200 : 417 } # about_page.html.erb
    format.json { render :json => @configuration.to_json }
    format.xml  { render :xml  => @configuration.to_xml }
  end
end