Add to node creation form

agentrickard - June 4, 2007 - 18:24
Project:Menu per Role
Version:5.x-1.x-dev
Component:Code
Category:feature request
Priority:normal
Assigned:Unassigned
Status:needs work
Description

The following patch extends menu_per_role_form_alter() to attach the menu_per_role form items to a node create / node edit form.

It requires a minor change in menu_per_role_form_submit(), since the menu data is nested inside a 'menu' array when coming from the node form.

AttachmentSize
mpr.patch1.71 KB

#1

agentrickard - June 4, 2007 - 19:30
Status:active» needs review

#2

fago - June 7, 2007 - 12:22
Status:needs review» needs work

hm, a nice feature, however I'm a bit worried that users don't like it there.
Could you add a new permission "Modify menu item access" or similar as well as checks for this permission to the module?

Then administrators could disable this for some users.

#3

agentrickard - June 8, 2007 - 14:08

Makes sense. I even thought of that. So menu_per_role() would have a setting:

[] show menu options on node forms

Or should this be an access control rule?

"assign during node edit"

#4

fago - June 9, 2007 - 13:05

I can think of two ways:
* add an access control permission like "Modify menu item access" - which would in affect allow one to remove it from node forms for certain users based on roles
* we create a settings page and add the setting "show menu options on node forms" *AND* add the access control permission from above.

 
 

Drupal is a registered trademark of Dries Buytaert.