Allow to override existing menu items
| Project: | Views |
| Version: | 6.x-2.x-dev |
| Component: | Code |
| Category: | feature request |
| Priority: | normal |
| Assigned: | sun |
| Status: | needs work |
Jump to:
As already mentioned in IRC, I have added the admin_views module to the admin_menu package.
name = Administration views
description = Replaces all system object management pages in Drupal core with real views.http://cvs.drupal.org/viewvc.py/drupal/contributions/modules/admin_menu/...
Let me first say that this is plain awesome - exactly what one would expect from a real content management system regarding administrative tasks.
However, for that to work properly, I need to be able to replace existing menu router items, which Views does not support currently.
Attached patch adds this option to the built-in page display handler - properly applying inheritance rules for any child router items. To use the admin_views module, you need to apply this patch to views.
I realize that this option may was left out intentionally, or that Views 3.x leveraging CTools's Page Manager might introduce this capability in a different way. However, I'm not sure about the development state of Views 3, and I really would like to push this admin_views awesomeness into the wild.
| Attachment | Size |
|---|---|
| views.menu-existing.patch | 6.21 KB |

#1
While debugging some unrelated menu system nightmares, I found a solid way to allow admin_views to override those items without hi-jacking the default menu items. That probably works for 99% of all use-cases. The 'existing' option added here would still be nice to have though.
#2
tracking
#3
I think I still have the basic UI problem that nobody who isn't VERY familiar with both Views and the Menu system will have any idea what this feature means, and people will set it incorrectly and it will screw things up. I understand the value but I think it would be best to have some other way.
#4
Thanks for coming back to me! :)
IIRC, we last talked about not introducing this in the "Page" display handler, but instead introducing a new "System" display handler. I think you mentioned that we refer to "system" in a couple of other places already. The only option for this handler would then be a system path - everything else is taken from the menu router.
That sounded also pretty sane to me. If you agree, I'd revamp this patch to accomplish that.
#5
Well, that's a CTools/Panels thing, and it doesn't do user-created overrides at all.
#6
I discovered this error b/c after installing Admin Views my admin/user/user/create page could not be found. It isn't clear from this discussion if this is fixed, but I did like the very brief opportunity I had to use admin pages created by views. Alas, it is off now until i know this is fixed. happy to test patches...
maria
#7
@Maria: exactly same thing :-(
#8
This patch fixed that problem of Error 403 for Create User for me. However, I just installed the 6.x-2.7 version of Views, and now I can't install users anymore. Guess I need to repatch. I'm sure hoping that the next version of Views includes this patch.
#9
I just installed the 6.x-2.8 version of Views, and again I need to add this patch so that I can create Users.
Also, please note that the changes the patch requires at
--- includes/view.inc (revision 687)
+++ includes/view.inc (working copy)
@@ -965,10 +965,14 @@ class view extends views_db_object {
should be done at lines 1008 instead of at 965.