Active
Project:
Node Relativity
Version:
5.x-1.x-dev
Component:
Miscellaneous
Priority:
Critical
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
14 Mar 2007 at 19:04 UTC
Updated:
30 Mar 2007 at 14:48 UTC
User A creates parent node.
User B cannot create child nodes for User A's parent node.
How can I fix this?
I have checked "Enforce Parental..." from Relativity's menu, but still only user A can create child nodes for his own parent node. Furthermore, user B can create orphan child nodes... But that's another issue.
I want anybody to be able to create child nodes (e.g. add pages to a book, or place bids for an auction).
Please help.
Comments
Comment #1
CloudCuckoo commentedAs far as I know for User B to be able to attach child nodes to User A's parent node User B needs the edit not edit own permission for the parent node's content type.
Using your auction example Users A and B need to be in a role that has the
- create auction content
- edit auction content
- create bid content
- edit bid content
permissions set for it.
The downside is that User B would also be able to edit the parent node, see issue at http://drupal.org/node/92552.
Comment #2
JohnG-1 commentedomar's patch : http://drupal.org/node/92552 is very simple and changes default child-bearing rules to promiscuous.
All the patch does is change one line to remove the node_access check (= node-edit permission) from the add child function. It works well and IMO is preferable default behaviour. But it is nice to know you could change it back for blogbooks if you ever wanted to ... :)
Comment #3
andrew7 commentedFantastic guys. Thanx a bunch!
Omar's patch works and IMHO too it should be default behavior.
Comment #4
darius commentedUntil a better overhaul of permissions issues in node relativity, I would rather keep the existing behavior as default, since changing it might affect a lot of people. Please remember that the current one line change is in the *theme* function, which means you can suit to y6our own needs as much as you want. Theme functions are meant to be changed by users.
Comment #5
JohnG-1 commented@ darius - default behaviour - fair enough.
@ darius - your 'theme_' hint - you mean hacking a
function phptemplate_relativity_linksinto yournode-#parent_type.tpl.phpto liberate #parent_type nodes ? hmm... crude but effective ;)Comment #6
JohnG-1 commentedHows about including 3 more select options foreach node-type relationship :?
admin/settings/relativity/advanced ->
Options for #parenttype (#parenttype) nodes:
Does that sound too complicated? (In know, I know ... patches are always welcome ... ;) But does the logic allow all the UI permissions-flexibility we could possibly need ?
Comment #7
JohnG-1 commentedanother problem with current permission check system:
If a node may only have one parent and then a clumsy user manages to 'Remove' the node from it's parent; the poor little orphan is lost! The only way I can figure to re-attach it is temporarily set the orphan's node type to [parent any], 'Attach existing ...' from the parent node, and then reset. This is a nuisance for site Admin.
Comment #8
JohnG-1 commentedOne solution to #7 would be to
hide 'Remove' links if the (child) node's parent ordinality is set to "one"
... so that the only way to 'Remove' that child is to delete the node. Does that make sense ?