Class: Boilerman::ControllersController

Inherits:
ApplicationController show all
Defined in:
app/controllers/boilerman/controllers_controller.rb

Instance Method Summary collapse

Instance Method Details

#indexObject



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

def index
  @with_actions = []
  @without_actions = []
  @controller_filters = []

  @controllers = filtered_controllers
  @controllers_and_callbacks = @controllers.map do |controller|
    callbacks = controller._process_action_callbacks
    [controller, callbacks.select{|callback| callback.kind == :before}.map(&:filter)]
  end

  gon.controllers = @controllers.map{|x| x.to_s}
end