diff options
author | Dries Buytaert <dries@buytaert.net> | 2004-04-15 20:49:42 +0000 |
---|---|---|
committer | Dries Buytaert <dries@buytaert.net> | 2004-04-15 20:49:42 +0000 |
commit | 10bdb51c37dd832f6bddd3364c19973a7540dda1 (patch) | |
tree | ee44dadbbf67e90a9c30bd709888add4c2503c67 /modules/watchdog | |
parent | a083daf8418d1dc6e0cbc5b41924c9d364815f9e (diff) | |
download | brdo-10bdb51c37dd832f6bddd3364c19973a7540dda1.tar.gz brdo-10bdb51c37dd832f6bddd3364c19973a7540dda1.tar.bz2 |
- Patch by JonBob/Jonathan: reworked the menu system so that menus are
configurable! Menu items can be disabled, repositioned, added and
so on.
Upgrading to requires you to run update.php.
This functionality depricates some of the 'navigation modules' in the
contributions repository. Furthermore, modules can now 'suggest'
menu items and site adminstrators can choose to enable them. Modules
in the contributions repository should try to take advantage of this.
Diffstat (limited to 'modules/watchdog')
-rw-r--r-- | modules/watchdog/watchdog.module | 10 |
1 files changed, 4 insertions, 6 deletions
diff --git a/modules/watchdog/watchdog.module b/modules/watchdog/watchdog.module index e0b1c38d2..e7ac001c1 100644 --- a/modules/watchdog/watchdog.module +++ b/modules/watchdog/watchdog.module @@ -52,13 +52,11 @@ function watchdog_perm() { function watchdog_link($type) { if ($type == "system") { if (user_access("administer watchdog")) { - if (arg(0) == 'admin') { // avoid SQL queries if possible - menu("admin/watchdog", t("logs"), "watchdog_admin", 7); - menu("admin/watchdog/view", t("view details"), "watchdog_admin", 0, MENU_HIDE); + menu("admin/watchdog", t("logs"), "watchdog_admin", 7); + menu("admin/watchdog/view", t("view details"), "watchdog_admin", 0, MENU_HIDE, MENU_LOCKED); - foreach (_watchdog_get_message_types() as $type) { - menu("admin/watchdog/$type", t($type), "watchdog_admin"); - } + foreach (_watchdog_get_message_types() as $type) { + menu("admin/watchdog/$type", t($type), "watchdog_admin"); } } } |