Class: Alchemy::Admin::LayoutpagesController

Inherits:
BaseController show all
Defined in:
app/controllers/alchemy/admin/layoutpages_controller.rb

Instance Method Summary collapse

Methods inherited from BaseController

#leave

Methods included from Modules

included, #module_definition_for, register_module

Methods included from Alchemy::AbilityHelper

#current_ability

Methods included from ConfigurationMethods

#configuration, #multi_language?, #multi_site?, #prefix_locale?

Instance Method Details

#editObject



11
12
13
14
# File 'app/controllers/alchemy/admin/layoutpages_controller.rb', line 11

def edit
  @page = Page.find(params[:id])
  @page_layouts = PageLayout.layouts_with_own_for_select(@page.page_layout, Language.current.id, true)
end

#indexObject



6
7
8
9
# File 'app/controllers/alchemy/admin/layoutpages_controller.rb', line 6

def index
  @layout_root = Page.find_or_create_layout_root_for(Language.current.id)
  @languages = Language.all
end