How to change Main Menu

Added by Reiner Lichtenberger 4 months ago

Hi,
is it possible to delete or change top menu bar:
Home
My page
Projects
Administration
Help

I want to remove "Help"
thx
RL

Replies (7)

RE: How to change Main Menu - Added by Mayama Takeshi 4 months ago

There might be a simpler way but you could use this plugin:
https://www.redmine.org/plugins/redmine_custom_js

Then configure it with this code to remove the menu item:

$(document).ready(function() {
  $(".help").remove()
})

RE: How to change Main Menu - Added by Reiner Lichtenberger 4 months ago

thx, but does not fit with Version 4.x
other ideas?

RE: How to change Main Menu - Added by Mayama Takeshi 4 months ago

I'm using 4.1.1.
It works for me:

RE: How to change Main Menu - Added by Reiner Lichtenberger 4 months ago

thx.
I ll try to remove this in redmine.rb
  1. menu.push :help, Redmine::Info.help_url, :last => true
    is a new start of apache always necessary?
    Thx

RE: How to change Main Menu - Added by Mayama Takeshi 4 months ago

Usually, yes.

RE: How to change Main Menu - Added by Mischa The Evil 4 months ago

FWIW: I recommend against patching Redmine core files or using JavaScript hacks with additional plugin dependencies for something as small as this.
I suggest you just utilize the designated plugin API for this. A simple plugin would consist of something along the lines of an 'init.rb' file that looks like:

Redmine::Plugin.register :remove_top_menu_help do
  name 'Remove Top Menu Help Item'
  author 'Mischa The Evil'
  description 'A tiny Redmine plugin to remove the top menu help item.'
  version '0.0.1'
  url 'https://www.redmine.org/boards/1/topics/59964'
  author_url 'https://www.redmine.org/users/1565'

  # Remove the help item from the top menu
  delete_menu_item :top_menu, :help
end

Now place that file into a new directory named 'remove_top_menu_help' in your Redmine's 'plugins' directory and restart your Redmine environment. Et voila...

RE: How to change Main Menu - Added by Reiner Lichtenberger 4 months ago

this:

I ll try to remove this in redmine.rb

menu.push :help, Redmine::Info.help_url, :last => true
is a new start of apache always necessary?
Thx

works out, thx to all

(1-7/7)