Class: TableHeaderComponent

Inherits:
ViewComponent::Base
  • Object
show all
Defined in:
lib/alveole/components/table_header_component.rb

Instance Method Summary collapse

Constructor Details

#initialize(label: nil, url: nil, obj: nil, fieldname: nil) ⇒ TableHeaderComponent

Returns a new instance of TableHeaderComponent.



2
3
4
5
6
7
# File 'lib/alveole/components/table_header_component.rb', line 2

def initialize(label: nil, url: nil, obj: nil, fieldname: nil)
  super

  @label = label || ApplicationController.helpers.label_for(obj, fieldname)
  @url = url
end