Project

General

Profile

Actions

Feature #1729

closed

Extend plugin top_menu with class

Added by Michael Pirogov over 15 years ago. Updated over 15 years ago.

Status:
Closed
Priority:
Normal
Assignee:
-
Category:
Plugin API
Target version:
-
Start date:
2008-08-01
Due date:
% Done:

0%

Estimated time:
Resolution:

Description

Will be good for attaching an icon.

For example:
menu :top_menu, "Timeplan", :controller => 'timeplan', :action => 'index', :html => { :class => 'icon myicon' }

Actions #1

Updated by Eric Davis over 15 years ago

  • Status changed from New to Resolved

I just tested this with trunk r1921 and it worked. Can you give it a try?

# init.rb
menu :top_menu, :bulk_time_entry, {:controller => "bulk_time_entries", :action => 'index'}, 
     :caption => :bulk_time_entry_title, :html => { :class => 'icon myicon' }, :if => Proc.new{User.current.logged?} 
# Rendered html
<li><a class="icon myicon" href="/bulk_time_entries">Bulk time entries</a></li>
Actions #2

Updated by Jean-Philippe Lang over 15 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF