Class: Parts::Base
- Inherits:
-
AbstractController::Base
- Object
- AbstractController::Base
- Parts::Base
- Includes:
- AbstractController::Callbacks, AbstractController::Layouts, AbstractController::Rendering, AbstractController::Translation, ActionController::Helpers, ActionController::ImplicitRender, DefaultLayout
- Defined in:
- lib/parts/base.rb
Instance Attribute Summary collapse
-
#params ⇒ Object
readonly
Returns the value of attribute params.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(controller, params) ⇒ Base
constructor
A new instance of Base.
Methods included from DefaultLayout
Constructor Details
#initialize(controller, params) ⇒ Base
Returns a new instance of Base.
15 16 17 18 19 |
# File 'lib/parts/base.rb', line 15 def initialize(controller, params) @params = controller.params.dup @params.merge!(params) unless params.empty? self.formats = controller.formats end |
Instance Attribute Details
#params ⇒ Object (readonly)
Returns the value of attribute params.
5 6 7 |
# File 'lib/parts/base.rb', line 5 def params @params end |
Class Method Details
.inherited(klass) ⇒ Object
21 22 23 24 |
# File 'lib/parts/base.rb', line 21 def self.inherited(klass) super klass.helper :all end |