Module: EffectiveMenusAdminHelper
- Defined in:
- app/helpers/effective_menus_admin_helper.rb
Instance Method Summary collapse
Instance Method Details
#visible_badge(menu_item, stack, comparator) ⇒ Object
3 4 5 6 |
# File 'app/helpers/effective_menus_admin_helper.rb', line 3 def visible_badge(, stack, comparator) visible = comparator.call() && stack.all? { || .lft == 1 || comparator.call() } content_tag(:span, (visible ? 'YES'.freeze : 'NO'.freeze), :class => "label label-#{(visible ? 'primary' : 'warning')}") end |