Module: SimpleResourceController::Controller::Actions::Index

Defined in:
lib/simple_resource_controller/controller/actions.rb

Instance Method Summary collapse

Instance Method Details

#index(options = {}, &block) ⇒ Object Also known as: index!



5
6
7
8
9
10
11
12
13
14
15
# File 'lib/simple_resource_controller/controller/actions.rb', line 5

def index(options={}, &block)
  unless block_given?
    if current_controller_api?
      api_before_index_response_callback(options)
    else
      html_before_index_response_callback(options)
    end
  end

  respond_with collection, options, &block
end