Module: HighVoltage::StaticPage

Extended by:
ActiveSupport::Concern
Included in:
PagesController
Defined in:
app/controllers/concerns/high_voltage/static_page.rb

Instance Method Summary collapse

Instance Method Details

#current_pageObject


31
32
33
# File 'app/controllers/concerns/high_voltage/static_page.rb', line 31

def current_page
  page_finder.find
end

#page_finderObject


35
36
37
# File 'app/controllers/concerns/high_voltage/static_page.rb', line 35

def page_finder
  page_finder_factory.new(params[:id])
end

#page_finder_factoryObject


39
40
41
# File 'app/controllers/concerns/high_voltage/static_page.rb', line 39

def page_finder_factory
  HighVoltage::PageFinder
end

#showObject


27
28
29
# File 'app/controllers/concerns/high_voltage/static_page.rb', line 27

def show
  render template: current_page
end