Sha256: 4863c2537f588ea1f5f966225701c26d840344fe64638dcaa920cb64e16e83b8

Contents?: true

Size: 251 Bytes

Versions: 9

Compression:

Stored size: 251 Bytes

Contents

module Redde::Layout
  extend ActiveSupport::Concern

  included do
    layout :layout_by_resource
  end

  def layout_by_resource
    if devise_controller? && controller_name == 'sessions'
      'login'
    else
      'application'
    end
  end
end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
redde-0.1.18 lib/redde/concerns/layout.rb
redde-0.1.17 lib/redde/concerns/layout.rb
redde-0.1.16 lib/redde/concerns/layout.rb
redde-0.1.15 lib/redde/concerns/layout.rb
redde-0.1.14 lib/redde/concerns/layout.rb
redde-0.1.13 lib/redde/concerns/layout.rb
redde-0.1.12 lib/redde/concerns/layout.rb
redde-0.1.11 lib/redde/concerns/layout.rb
redde-0.1.10 lib/redde/concerns/layout.rb