node_privacy_byrole and event with volunteer time slots

berndpostma - December 1, 2006 - 09:56
Project:Event with volunteer time slots
Version:4.7.x-1.x-dev
Component:User interface
Category:bug report
Priority:normal
Assigned:berndpostma
Status:closed
Description

The checkboxes belonging to the roles (module: node_privacy_byrole) below, clear after somebody has entered themself as volunteer. As administrator I have to but rhe rights back for other to be able to see the event with volunteer time slot. What do I do wrong or is it a bug?

View/Edit Permissions
View/Edit Permissions:
Role View Edit
administrator
anonymous user
authenticated user

Select which users can view/edit your post based on their role.

#1

pwolanin - December 4, 2006 - 16:42

When someone signs up as a volunteer, my code actually does a node load, changes values as needed, and then does a node save forcing a new revision of the node.

So, it looks like problem is that node_privacy_byrole is broken since it assumes that all node_save() operations happen as a result of a form submission. One possible fix (I don't know if this would solve it) would be to implement the 'load' op in hook_nodeapi to make sure the necessary fields are always present.

Also, there is some pretty ugly code in this module- looks like it never got a thorough upgrade to 4.7, and doesn't look like it's getting much love in the issue queue http://drupal.org/project/issues/node_privacy_byrole, and no recent commits: http://drupal.org/project/cvs/11598.

#2

pwolanin - January 5, 2007 - 02:13
Status:active» closed
 
 

Drupal is a registered trademark of Dries Buytaert.