Menu Weight Advanced is module, which helps to create the node menu entry (item) in the right location in the menu structure. In the node edit view "Menu settings" section the "Weight" field is replaced with the drag & drop table containing the "Parent item" children items. The node menu entry (item) can be dragged and dropped to the right place within the table.
The screenshot of the overriden "Menu settings" block is attached (mwadd-screenshot.png).

The closest module which tries to help with setting up the menu item weight in the node edit form is Menu Weight Assist.

CommentFileSizeAuthor
mwadd-screenshot.png61 KBnor4a

Comments

nor4a’s picture

nor4a’s picture

Added the menu weight drag & drop functionality to the Menu Link editing form.

avpaderno’s picture

Status: Active » Needs review
joachim’s picture

Status: Needs review » Needs work

Good idea!

Gave it a spin and it's pretty handy.

But needs a better name. 'Advanced' is hardly ever a good word to use in a name.
Also, needs a better machine name than mwadd.

- $Id$ lines are obsolete
- code should not include author credit; that goes in the git commit log ;)
- use sentence case in module info name
- module info description is a bit too long!
- "The new menu item*" a bit shouty and red! Just 'New item' will do probably, or since you're using ajax anyway, can you lift the title field text? I don't think the red is needed either; bold suffices.
- 'Changes made in this table will not be saved until the form is submitted' -- any way to suppress this? it's redundant here!
- Whenever I see $_POST I think something's not right:
$mwadds = $_POST['mwadd'];
Where are you putting that in?

nor4a’s picture

Title: Menu Weight Advanced » Menu Weight Advanced ==> Menu Order
Component: new project application » module
Status: Needs work » Needs review

Thanks, joachim for goot tips to improve the module!
I think the best name for the module is "Menu Order" - it is short and names exactly the thing it is doing.
I cleaned up the code and did all your suggestions to improve the UI and code.
I'm using standard Drupal Table Drag&Drop API and I did not find the way howe to remove the message: ''Changes made in this table will not be saved until the form is submitted"
I'm using $_POST[], because I did not find the way how to get the form parameters which are submitted through Ajax in the functions: menu_order_nodeapi and menu_order_menu_link_alter. I should get the POST array to have all the ordering information passed from Drag&Drop table.

Thanks!

ralt’s picture

Title: Menu Weight Advanced ==> Menu Order » Menu Order
Priority: Normal » Critical

Changing priority according to the new priority guidelines.

(Also changing the title)

davidhernandez’s picture

On the topic of module duplication, how does this module differ from menu weight assist? Since menu weight assist doesn't appear to be actively maintained, it might be better to take over development of that project and add your functionality to it.

davidhernandez’s picture

Status: Needs review » Needs work
ParisLiakos’s picture

Priority: Critical » Normal
nor4a’s picture

Status: Needs work » Needs review

The module does not "Assist" it realy allows to put the menu item at the right place in the menu structure by dragging and dropping the element.
No problem to replace the Menu Assist module with this one. If we do that - the better naming will be "Menu Order" , because of the module functionality.

klausi’s picture

Status: Needs review » Needs work

* git release branch is missing, see http://drupal.org/node/1015226
* README.txt is missing
* info file: Remove "version", this is added by drupal.org packaging automatically
* menu_order.js: please take the javascript coding standards into account (indentation, braces) http://drupal.org/node/172169
* module file: @file doc block is missing, see http://drupal.org/node/1354#files
* menu_order_menu_link_alter() is a hook implementation, right? document that.
* All important functions need doc blocks.
* "else:" code style, always use {} around if/else
* "explode( ':', $_POST['menu']['parent']);" function calls have no space after '('
* menu_order_nodeapi(): the switch() structure is not needed here as there are only 2 relevant options. Use an if statement instead.

jthorson’s picture

Status: Needs work » Closed (duplicate)

It appears that there have been multiple project applications opened under your username:

Menu Order: http://drupal.org/node/1081128
Nodeorder Field: http://drupal.org/node/1091360

As successful completion of the project application process results in the applicant being granted the 'Create Full Projects' permission, there is no need to take multiple applications through the process. Once the first application has been successfully approved, then the applicant can promote other projects without review. Because of this, posting multiple applications is not necessary, and results in additional workload for reviewers ... which in turn results in longer wait times for everyone in the queue.

With this in mind, I have marked your secondary applications as 'closed(duplicate)', and left one application open (chosen at random).

If you prefer that we proceed through this review process with a different application than the one I that I have left open, then please feel free to close the 'open' application as a duplicate, and re-open one of the other project applications which I had closed.

Thanks in advance for your patience and understanding!

avpaderno’s picture

Title: Menu Order » [D6] Menu Order
Issue summary: View changes
Related issues: +#1091360: [D6] Nodeorder Field