diff --git a/lib/redmine.rb b/lib/redmine.rb index 5f01787c2dff6a61f49d2ea106906fde71ccc2e1..0dda94e95df22fd86dc338ccb91347ecf0ae2403 100644 --- a/lib/redmine.rb +++ b/lib/redmine.rb @@ -213,9 +213,10 @@ Redmine::MenuManager.map :application_menu do |menu| menu.push :time_entries, {:controller => 'timelog', :action => 'index'}, :if => Proc.new {User.current.allowed_to?(:view_time_entries, nil, :global => true)}, :caption => :label_spent_time - menu.push :gantt, { :controller => 'gantts', :action => 'show' }, :caption => :label_gantt - menu.push :calendar, { :controller => 'calendars', :action => 'show' }, :caption => :label_calendar - + menu.push :gantt, { :controller => 'gantts', :action => 'show' }, :caption => :label_gantt, + :if => Proc.new {User.current.allowed_to?(:view_gantt, nil, :global => true)} + menu.push :calendar, { :controller => 'calendars', :action => 'show' }, :caption => :label_calendar, + :if => Proc.new {User.current.allowed_to?(:view_calendar, nil, :global => true)} menu.push :news, {:controller => 'news', :action => 'index'}, :if => Proc.new {User.current.allowed_to?(:view_news, nil, :global => true)}, :caption => :label_news_plural