Sha256: 63b48df355730b09303b9bfc9d1fab71069ddaa86013755ba5b75d4202d5a0b6

Contents?: true

Size: 1.08 KB

Versions: 47

Compression:

Stored size: 1.08 KB

Contents

# frozen_string_literal: true

class ApplicationController < ActionController::Base

  # Don't expose any of these methods as action_methods
  protected

  def navbar_partial(partial = nil)
    @partial_navbar = partial if partial
    return @partial_navbar if defined? @partial_navbar

    @partial_navbar = 'layouts/navbar'
  end
  helper_method :navbar_partial

  def footer_partial(partial = nil)
    @partial_footer = partial if partial
    return @partial_footer if defined? @partial_footer

    @partial_footer = 'layouts/footer'
  end
  helper_method :footer_partial

  # Useful for scripts that go just before </head>
  def head_partial(partial = nil)
    @partial_head = partial if partial
    return @partial_head if defined? @partial_head

    @partial_head = 'layouts/head'
  end
  helper_method :head_partial

  # Useful for scripts that go just before </body>
  def body_end_partial(partial = nil)
    @partial_body_end = partial if partial
    return @partial_body_end if defined? @partial_body_end

    @partial_body_end = 'layouts/body_end'
  end
  helper_method :body_end_partial
end

Version data entries

47 entries across 47 versions & 1 rubygems

Version Path
rails_app_generator-0.2.30 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.29 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.28 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.27 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.26 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.25 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.24 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.23 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.22 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.21 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.20 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.19 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.18 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.17 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.16 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.15 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.14 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.13 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.12 after_templates/application/printspeak/app/controllers/application_controller.rb
rails_app_generator-0.2.11 after_templates/application/printspeak/app/controllers/application_controller.rb