Class: Super::Controls
- Inherits:
-
Object
- Object
- Super::Controls
- Defined in:
- lib/super/controls.rb
Overview
A wrapper around the per-controller Controls classes. This class often directly delegates to the per-controller classes, but it can also provide some default implementation.
Instance Attribute Summary collapse
-
#actual ⇒ Object
readonly
Returns the value of attribute actual.
Instance Method Summary collapse
- #display_schema(action:) ⇒ Object
- #form_schema(action:) ⇒ Object
-
#initialize(actual) ⇒ Controls
constructor
A new instance of Controls.
- #model ⇒ Object
- #permitted_params(params, action:) ⇒ Object
- #scope(action:) ⇒ Object
- #title ⇒ Object
Constructor Details
#initialize(actual) ⇒ Controls
Returns a new instance of Controls.
6 7 8 |
# File 'lib/super/controls.rb', line 6 def initialize(actual) @actual = actual end |
Instance Attribute Details
#actual ⇒ Object (readonly)
Returns the value of attribute actual.
10 11 12 |
# File 'lib/super/controls.rb', line 10 def actual @actual end |
Instance Method Details
#display_schema(action:) ⇒ Object
32 33 34 |
# File 'lib/super/controls.rb', line 32 def display_schema(action:) @actual.display_schema(action: action) end |
#form_schema(action:) ⇒ Object
37 38 39 |
# File 'lib/super/controls.rb', line 37 def form_schema(action:) @actual.form_schema(action: action) end |
#model ⇒ Object
16 17 18 |
# File 'lib/super/controls.rb', line 16 def model @actual.model end |
#permitted_params(params, action:) ⇒ Object
27 28 29 |
# File 'lib/super/controls.rb', line 27 def permitted_params(params, action:) @actual.permitted_params(params, action: action) end |
#scope(action:) ⇒ Object
21 22 23 |
# File 'lib/super/controls.rb', line 21 def scope(action:) @actual.scope(action: action) end |
#title ⇒ Object
12 13 14 |
# File 'lib/super/controls.rb', line 12 def title @actual.title end |