Module: BreadcrumbHelper
- Defined in:
- app/helpers/breadcrumb_helper.rb
Instance Method Summary collapse
- #p_breadcrumb(id, options = {}, &block) ⇒ Object
- #p_breadcrumb_menu(id, options = {}) ⇒ Object
- #render_breadcrumbs(&block) ⇒ Object
Instance Method Details
#p_breadcrumb(id, options = {}, &block) ⇒ Object
12 13 14 15 |
# File 'app/helpers/breadcrumb_helper.rb', line 12 def (id,={},&block) output = (id,,&block) output += (id,) end |
#p_breadcrumb_menu(id, options = {}) ⇒ Object
17 18 19 20 21 22 |
# File 'app/helpers/breadcrumb_helper.rb', line 17 def (id,={}) = .stringify_keys content_tag(:li, ) do content_tag(:a, ['value'], href: ['url']) end end |
#render_breadcrumbs(&block) ⇒ Object
3 4 5 6 7 8 9 10 |
# File 'app/helpers/breadcrumb_helper.rb', line 3 def (&block) content = render :partial => 'prime-rails/breadcrumbs', :layout => false if block_given? capture(content, &block) else content end end |