Closed (fixed)
Project:
Drupal core
Version:
6.x-dev
Component:
menu system
Priority:
Critical
Category:
Task
Assigned:
Reporter:
Created:
29 May 2007 at 13:52 UTC
Updated:
20 Jun 2007 at 06:50 UTC
Jump to comment: Most recent file
Exactly three years ago I registered on drupal.org. Let's celebrate with some nice... patches :D
| Comment | File | Size | Author |
|---|---|---|---|
| #17 | update_item_validation_3.patch | 1000 bytes | flk |
| #16 | update_item_validation_2.patch | 1006 bytes | flk |
| #15 | update_item_validation.patch | 1.06 KB | flk |
| #13 | menu_module_14.patch | 47.2 KB | pwolanin |
| #12 | menu_module_13.patch | 47.21 KB | pwolanin |
Comments
Comment #1
chx commentedThis is menu module. Add/edit menus and items; enable, reset, delete items; use menu otf.
Comment #2
pwolanin commentedhappy 3rd year of Drupal!
Setting to critical (since it is)
Starting to review the patch. Why are you removing this code?
I added submitted this as a menu.inc patch (http://drupal.org/node/145058#comment-250460) because without this code the has_children flag remains inappropriately set when items are deleted (I saw this problem while converting the book module to the menu API).
Comment #3
chx commentedThat's a bad merge, if you remember it was a separate patch and surely I merged wrong at one point.
Comment #4
Rok Žlender commented1. I was getting unintialized variable notice problem was on line 599 in menu.module variable has to be initialized before appending new values. I updated the patch.
2. When navigating to Administer->Site building->Menus I get 3 default menus but when clicking on List tab on this page I get top level links from Navigation menu (My Account, Create Content, Administer,...). I havent found why this is happening yet.
Comment #5
bennybobw commentedOn a clean CVS, applying menu_module_patch_9, I'm getting:
Uploading the .rej file.
Comment #6
bennybobw commentedFile didn't get uploaded.
Comment #7
chx commentedRerolled against HEAD.
Comment #8
chx commentedRerolled against current HEAD. doh.
Comment #9
chx commentedAn error fixed and Zlender actually stubmled upon http://drupal.org/node/115847 -- he landed on the bogus path of admin/build/menu/list which tried to list the items in the 'list' menu which obviously failed. On a subsequent patch we might want to fix this but as there are some upcoming changes /fixes to menu , I am not too inclined for it.
Comment #10
morphir commentedsubscribing to this (too many menu issues :P)
Comment #11
flk commentedpatches with no error.
I can add menu's but there is no option to delete the created menus (maybe i am missing something)
I added items to the created menu:normal menus with links to internal and external links.
I edited one of the external linked menu and replaced the path with '1' which in turn brought about this fugly error:
No way to get rid of the created sub-menu since it no longer shows up in UI.
I am trying a quick and dirty backtrace will see if i can follow it
Comment #12
pwolanin commentedI think this code you're adding to menu.inc in
would be better off in menu.module rather than in menu.inc. For example, if the menu.inc framework is used by book, I think this message would be confusing to see any time a node is deleted.
Found a bug in the add menu code- it should check if the menu_name already exits in {menu_links}, not just {menu_custom}.
Attached patch changes these two things.
Also, the tabs are a bit confusing- patch changes the default tab titles to "List menus" and "List items" . Otherwise it wasn't clear to me that I was on a different set of tabs.
There seems to be no interface for deleting a menu - is that coming later?
Disabling a node link is a custom menu generates this error:
Seems
&$form_statewas added as a first parameter by mistake. Fixed in this patch.Comment #13
pwolanin commentedAttached patch fixes block titles and deltas.
Comment #14
dries commentedCommitted to CVS HEAD. Thanks.
Comment #15
flk commentedmenu_edit_item_validate() is bit behind times, since wrong variable names was being used internal paths were not getting validated.
refer to #11 for example.
Comment #16
flk commentedwell first of all the $items was getting overwritten in the 2nd loop making some of the references such as $item['original_item']['link_path'] etc in undefined... also spoke to chx who informed me there was he 'unaware of any problems with a path repeating in a menu'.
Therefore removed the elseif statement check.
Comment #17
flk commentedremoved the whole else/elseif check for items pointing to the same path.
since pointing different items to the same path will not cause conflict i do not think this is really necessary..users can have as many items pointing to the same path as they want (yes it is inefficient but really that's not our problem)
Comment #18
flk commentedComment #19
agentrickardPatch prevents the creation of invalid internal paths.
Perhaps the #description for $form['link_path'] should say "'The path this menu item links to. This can be a valid internal Drupal path..." but that doesn't mean this isn't RTBC.
Comment #20
chx commentedNote that with the new system this is a must. You can't add links first, pages second because the menu system would spit errors all around. It's faster on page load time if we do not allow this.
Comment #21
pwolanin commented@chx: I'm loosing track- is there a separate issue with the 5.x to 6.x update code?
Comment #22
pwolanin commentedsorry - didn't mean to change the status; found the issue with the update code: http://drupal.org/node/147657
Comment #23
dries commentedCommitted to CVS HEAD. Thanks.
Comment #24
(not verified) commented