Sha256: a0d6b7c9a00ecf7b9b093ac79e4fe822f54055576f18d997c5f06e2552edc2ea

Contents?: true

Size: 591 Bytes

Versions: 3

Compression:

Stored size: 591 Bytes

Contents

class Cms::MainController < Cms::SetupController
  unloadable
  extend Cms::RoleAuthentication

  layout 'cms'

  before_filter :load_resources

  authenticate_user :all, :only => %w(index)

  def index
    render :partial => 'cms/shared/index', :layout => true
  end

protected
  def load_resources
    @context = Cms::Context.new(@cms_context)

    @cms_pages = @context.pages.ordered.all(:conditions => {:layout_page_id => nil})
    @cms_assets = @context.assets.ordered
    @cms_components = @context.components

    @context_asset_tags = Cms::Asset.tags_for_context(@context)
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
liquid_cms-0.2.2.0 app/controllers/cms/main_controller.rb
liquid_cms-0.2.1.1 app/controllers/cms/main_controller.rb
liquid_cms-0.2.1.0 app/controllers/cms/main_controller.rb