Class: RailsInfo::Logs::Server::ActionPresenter
- Defined in:
- app/presenters/rails_info/logs/server/action_presenter.rb
Instance Method Summary collapse
-
#initialize(subject, options = {}) ⇒ ActionPresenter
constructor
A new instance of ActionPresenter.
- #tabs ⇒ Object
Methods inherited from Presenter
Constructor Details
#initialize(subject, options = {}) ⇒ ActionPresenter
Returns a new instance of ActionPresenter.
2 3 4 5 6 7 8 |
# File 'app/presenters/rails_info/logs/server/action_presenter.rb', line 2 def initialize(subject, = {}) super(subject, ) @name = [:name] @tabs_data = [:tabs_data] @index = [:index] end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class RailsInfo::Presenter
Instance Method Details
#tabs ⇒ Object
10 11 12 13 14 15 16 17 18 |
# File 'app/presenters/rails_info/logs/server/action_presenter.rb', line 10 def tabs html = content_tag :h3, link_to(@name, '#') html += content_tag(:div, class: 'tabs', id: "tabs-#{@index}") do raw() + raw(body) end html end |