Sha256: f8df6bd59385d3fce62f9f331a4795d6e967fb457478b9657f23face906b2b3e

Contents?: true

Size: 410 Bytes

Versions: 71

Compression:

Stored size: 410 Bytes

Contents

class CamaleonCms::Apps::ThemesFrontController < CamaleonCms::FrontendController
  before_action :init_theme

  private

  def init_theme
    theme_name = params[:controller].split("/")[1]
    @theme = current_theme
    return render_error(404) unless current_theme.slug == theme_name
    lookup_context.prefixes.prepend(params[:controller].sub("themes/#{theme_name}", "themes/#{theme_name}/views"))
  end
end

Version data entries

71 entries across 71 versions & 2 rubygems

Version Path
camaleon_cms-2.4.6.1 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.6.0 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.5.14 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.5.13 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.5.12 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.5.11 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.5.10 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.5.9 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.5.8 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.5.7 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.5.5 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.5.4 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.5.3 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.5.2 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.5.1 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.5 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.4.7 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.4.6 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.4.5 app/controllers/camaleon_cms/apps/themes_front_controller.rb
camaleon_cms-2.4.4.4 app/controllers/camaleon_cms/apps/themes_front_controller.rb