Closed (fixed)
Project:
Node Relativity
Version:
6.x-1.x-dev
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Reporter:
Created:
18 May 2009 at 11:43 UTC
Updated:
3 Aug 2010 at 00:33 UTC
Jump to comment: Most recent file
Comments
Comment #1
jjalocha commentedJoonas, your patch seems to solve exactly the issue I am facing now: I need that other users than the authors are able to link the nodes, or create child nodes.
I would like to test your patch, but I don't know hot to patch software! Yesterday I downloaded a module from CVS for the first time in my life, under the guidance of the module author.
Maybe you could help me with this patch?
Thank you for your work.
Cheers,
Jerzy
PS: The Relativity access module seems to do the same thing for Drupal 5?
Comment #2
merilainen commentedI modified dev-version of relativity-module, so you should be able to patch it with the common instructions http://drupal.org/patch/apply
I made this patch for my own use, and decided to share it here, because I remembered that someone had similar problems, I just couldn't find the right thread. Maybe there is something what could be applied to next dev-version of relativity.
I didn't notice Relativity access module, they should update it for Drupal 6. They probably have put more thought to the functionality than me, after 5 minutes of "braistorming" :)
Comment #3
jjalocha commentedJoonas, I've been reviewing the possible solutions, and your patch might be the only single alternative that is working right now:
All other promising D6 projects look semi-abandoned, or the authors have no time for development. I didn't go back to CCK Node reference with the additional modules, yet, but I doubt that this provides as much functionality as any of the "hardcore" relationship modules.
Thank you very much for the patching instructions, I was able to apply it, and am testing it right now.
Cheers,
Jerzy
Comment #4
jjalocha commentedJoonas, your patch seems to run without flaws for child nodes with exactly one parent.
For Parental Ordinality of 'any', I get the following errors:
Setup Details
Three content types:
With 'Enforce Parental Rules' setting.
Two users & roles:
Test Details
Comment #5
jjalocha commentedUpdate to the previous tests
I get exactly the same test results as above with all combinations of the following settings:
This effectively means, that this patch can't deal right now with nodes that do not have exactly 'one' parent.
*Actually, a parental ordinality of 'none' for the Resource node type is an invalid setting, because it conflicts with the 'Allowable Child Node types' setting of 'Resource' & 'Solution' in this test set-up. But this is an error in the Node relativity module, and not of this patch.
Comment #6
merilainen commentedThank you for testing my patch.
In my setup I only have one parent for my child, so I didn't even notice the existence of this "Attach existing content" functionality.
I do not understand all the logic behind the module, so it's quite probable that my patches won't work perfectly. Basically I'm just replacing all the
node_access('update', $node)calls withuser_access($permission)calls, which means that the user don't have to be the author of the node, but he needs to have permission to add/remove child nodes.To include this functionality in the module itself, we should define who can do and what more precisely.
Anyway I made another patch which you may try.
Comment #7
jjalocha commentedJoonas, I followed the complete testing procedure from post #4 on a clean install with patch2 and everything works perfect now. 'Attach existing Resource' gets linked as expected for all combinations of both users with both user's contents (on parents and children) .
I will keep working with this module, and report back if any issues or questions arise. (With due time, I'll also try to take a look into the code, and try to understand a little bit, even if I'm not a developper.)
I am really very thankful that you took the time to fix this issue that was not in your interest at all. I really want to give you a huge THANK YOU!
@darius: Do you plan to include this patch in the 1.x branch? I would surely volunteer as a tester :)
Cheers,
Jerzy
Comment #8
chawl commentedPatch is OK. Now "Create new child" link can be exposed without giving user the edit rights for the parent node type.
I am for that patch should be committed.
Comment #9
chawl commentedThus...
Comment #10
davea commented#6 is now committed.
Thanks,
Dave