Sha256: b3a72e16a7aada616c719d56a49a71fa9385390ac1b09f97185bc812de9e9abc

Contents?: true

Size: 539 Bytes

Versions: 8

Compression:

Stored size: 539 Bytes

Contents

module ActionView
  class Base
    
  	def rich_cms
  	  render :file => File.join(File.dirname(__FILE__), "..", "..", "..", "..", "app", "views", "rich_cms.html.erb") if display_rich_cms?
  	end
  	
    def display_rich_cms?
      !!session[:rich_cms].try(:fetch, :display, nil)
    end
  	
  	def link(name, options = nil)
  	  options = {:class => options || name.underscore} unless options.is_a?(Hash)
  	  link_to name, "#", options
  	end
  	
  	def rich_cms_tag(*args)
  	  Rich::Cms::Engine.to_content_tag *args
  	end

  end
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
rich_cms-2.0.7 lib/rich/cms/actionpack/action_view/base.rb
rich_cms-2.0.6 lib/rich/cms/actionpack/action_view/base.rb
rich_cms-2.0.5 lib/rich/cms/actionpack/action_view/base.rb
rich_cms-2.0.4 lib/rich/cms/actionpack/action_view/base.rb
rich_cms-2.0.3 lib/rich/cms/actionpack/action_view/base.rb
rich_cms-2.0.2 lib/rich/cms/actionpack/action_view/base.rb
rich_cms-2.0.1 lib/rich/cms/actionpack/action_view/base.rb
rich_cms-2.0.0 lib/rich/cms/actionpack/action_view/base.rb