Class: Georgia::ActiveFacetPresenter
- Defined in:
- app/presenters/georgia/active_facet_presenter.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#param ⇒ Object
readonly
Returns the value of attribute param.
-
#text ⇒ Object
readonly
Returns the value of attribute text.
Attributes inherited from Presenter
Instance Method Summary collapse
-
#initialize(view_context, text, param, options = {}) ⇒ ActiveFacetPresenter
constructor
A new instance of ActiveFacetPresenter.
- #to_s ⇒ Object
Constructor Details
#initialize(view_context, text, param, options = {}) ⇒ ActiveFacetPresenter
Returns a new instance of ActiveFacetPresenter.
6 7 8 9 10 11 |
# File 'app/presenters/georgia/active_facet_presenter.rb', line 6 def initialize view_context, text, param, ={} super @text = text @param = param = end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class Georgia::Presenter
Instance Attribute Details
#param ⇒ Object (readonly)
Returns the value of attribute param.
4 5 6 |
# File 'app/presenters/georgia/active_facet_presenter.rb', line 4 def param @param end |
#text ⇒ Object (readonly)
Returns the value of attribute text.
4 5 6 |
# File 'app/presenters/georgia/active_facet_presenter.rb', line 4 def text @text end |
Instance Method Details
#to_s ⇒ Object
13 14 15 16 17 |
# File 'app/presenters/georgia/active_facet_presenter.rb', line 13 def to_s link_to url_for(unmerged_params), class: 'label label-primary' do "#{text} #{icon_tag('times')}".html_safe end end |