Module: MetaController::Adaptors::ShowAction

Defined in:
lib/meta_controller/adaptors/show_action.rb

Instance Method Summary collapse

Instance Method Details

#show_actionObject



6
7
8
9
10
11
12
13
14
15
16
17
# File 'lib/meta_controller/adaptors/show_action.rb', line 6

def show_action
  controller_eval do
    define_callbacks :before_show_find
    define_callbacks :after_show_find
  end
  define_controller_method(:show, %{
    run_callbacks(:before_show_find)
    #{short_model_name}
    run_callbacks(:after_show_find)
    render_any #{short_model_name}, :action => 'form'
  })
end