Sha256: d7436a3635311558602d06ba8e861a24e4ab2ff3558aed9bc07e3e46326b90c2

Contents?: true

Size: 554 Bytes

Versions: 66

Compression:

Stored size: 554 Bytes

Contents

# Copied from Curate
module CurationConcerns::ThemedLayoutController
  extend ActiveSupport::Concern

  included do
    class_attribute :theme
    self.theme = 'curation_concerns'
    helper_method :theme
    helper_method :show_site_actions?
    helper_method :show_site_search?
  end

  module ClassMethods
    def with_themed_layout(view_name = nil)
      if view_name
        layout("#{theme}/#{view_name}")
      else
        layout(theme)
      end
    end
  end

  def show_site_actions?
    true
  end

  def show_site_search?
    true
  end
end

Version data entries

66 entries across 66 versions & 1 rubygems

Version Path
curation_concerns-1.7.8 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.7.7 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-2.0.0 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-2.0.0.rc2 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.7.6 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.7.5 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.7.4 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.7.3 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.7.2 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-2.0.0.rc1 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.7.1 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.7.0 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.7.0.beta1 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.6.3 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.6.2 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.6.1 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.6.0 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.5.0 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.4.0 app/controllers/concerns/curation_concerns/themed_layout_controller.rb
curation_concerns-1.3.3 app/controllers/concerns/curation_concerns/themed_layout_controller.rb