Class: Admin::PagesController

Inherits:
BaseController
  • Object
show all
Defined in:
app/controllers/admin/pages_controller.rb

Instance Method Summary collapse

Instance Method Details

#newObject



18
19
20
21
22
23
# File 'app/controllers/admin/pages_controller.rb', line 18

def new
  @page = Page.new
  Page.default_parts.each_with_index do |page_part, index|
    @page.parts << PagePart.new(:title => page_part, :position => index)
  end
end