Class: FlexiAdmin::Components::Shared::DatalistComponent
- Inherits:
-
BaseComponent
- Object
- ViewComponent::Base
- BaseComponent
- FlexiAdmin::Components::Shared::DatalistComponent
- Includes:
- Helpers::ResourceHelper
- Defined in:
- lib/flexi_admin/components/shared/datalist_component.rb
Instance Attribute Summary collapse
-
#action ⇒ Object
readonly
Returns the value of attribute action.
-
#disabled ⇒ Object
readonly
Returns the value of attribute disabled.
-
#parent ⇒ Object
readonly
Returns the value of attribute parent.
-
#resource ⇒ Object
readonly
Returns the value of attribute resource.
Instance Method Summary collapse
-
#initialize(resource = nil, scope: nil, disabled: false, parent: nil) ⇒ DatalistComponent
constructor
A new instance of DatalistComponent.
Methods included from Helpers::ResourceHelper
#autocomplete_path, #bulk_action_path, #datalist_path, #edit_resource_path, #paginate, #resource__path, #resource_input_name, #resource_path, #resources_path, #scope, #scope_plural, #scope_singular
Constructor Details
#initialize(resource = nil, scope: nil, disabled: false, parent: nil) ⇒ DatalistComponent
Returns a new instance of DatalistComponent.
11 12 13 14 15 16 17 18 |
# File 'lib/flexi_admin/components/shared/datalist_component.rb', line 11 def initialize(resource = nil, scope: nil, disabled: false, parent: nil) @resource = resource @scope = scope @parent = parent @action = action @disabled = disabled end |
Instance Attribute Details
#action ⇒ Object (readonly)
Returns the value of attribute action.
9 10 11 |
# File 'lib/flexi_admin/components/shared/datalist_component.rb', line 9 def action @action end |
#disabled ⇒ Object (readonly)
Returns the value of attribute disabled.
9 10 11 |
# File 'lib/flexi_admin/components/shared/datalist_component.rb', line 9 def disabled @disabled end |
#parent ⇒ Object (readonly)
Returns the value of attribute parent.
9 10 11 |
# File 'lib/flexi_admin/components/shared/datalist_component.rb', line 9 def parent @parent end |
#resource ⇒ Object (readonly)
Returns the value of attribute resource.
9 10 11 |
# File 'lib/flexi_admin/components/shared/datalist_component.rb', line 9 def resource @resource end |