Class: Blacklight::ConstraintPresenter
- Inherits:
-
Object
- Object
- Blacklight::ConstraintPresenter
- Defined in:
- app/presenters/blacklight/constraint_presenter.rb
Instance Attribute Summary collapse
-
#facet_item_presenter ⇒ Object
Returns the value of attribute facet_item_presenter.
-
#field_label ⇒ Object
Returns the value of attribute field_label.
Instance Method Summary collapse
-
#constraint_label ⇒ String
Get the displayable version of the facet’s value for use in e.g.
-
#initialize(facet_item_presenter:, field_label:) ⇒ ConstraintPresenter
constructor
A new instance of ConstraintPresenter.
Constructor Details
#initialize(facet_item_presenter:, field_label:) ⇒ ConstraintPresenter
Returns a new instance of ConstraintPresenter.
5 6 7 8 |
# File 'app/presenters/blacklight/constraint_presenter.rb', line 5 def initialize(facet_item_presenter:, field_label:) @facet_item_presenter = facet_item_presenter @field_label = field_label end |
Instance Attribute Details
#facet_item_presenter ⇒ Object
Returns the value of attribute facet_item_presenter.
10 11 12 |
# File 'app/presenters/blacklight/constraint_presenter.rb', line 10 def facet_item_presenter @facet_item_presenter end |
#field_label ⇒ Object
Returns the value of attribute field_label.
10 11 12 |
# File 'app/presenters/blacklight/constraint_presenter.rb', line 10 def field_label @field_label end |
Instance Method Details
#constraint_label ⇒ String
Get the displayable version of the facet’s value for use in e.g. the constraints widget
18 19 20 |
# File 'app/presenters/blacklight/constraint_presenter.rb', line 18 def constraint_label facet_item_presenter.label end |