Update fields in Drupal 6 CCK via another tool

0

I want to update the Drupal 6 CCK fields through a mini panel where certain users can only change their information.

I'm opting to upgrade out of being an area that customers already know and do not have to change environment, in the case of Drupal, which is used internally by the team to register some things.

I found a solution updating directly in the database, but, are not advising me, any suggestions in a more correct way?

    
asked by anonymous 05.02.2015 / 15:07

1 answer

0

I'm not quite sure if you want to allow some users to change only a few specific nodes or fields on all nodes of a given type.

If the idea is to allow them to only edit certain nodes the module ACL can solve your problem.

If the idea is to allow them to edit some CCK fields in a content type, the simplest option is to use the Field Permissions that allows the creation of permissions for each field. It's hard to set all the permissions, but you'll gain more control over your forms.

If none of these options meet your need, you can think of creating a new content type (say, "change_data") containing only the fields these new users can use. It then creates rules using the Rules module that changes the fields in question from the original node when content of type "change_data" is saved . Consider using the args () function to get required parameters from the URL.

Finally, the most robust form is create a custom module . In this module, create a custom form that changes only the desired fields of the nodes in question . In this case you will need to use the hook_menu to create the form page and use the drupal_get_form as the "page callback" and the name of the function that constructs the form as "page arguments ". In the 'submit' function of your form use hook_node_save to change the fields from the values provided in the form.

    
27.08.2015 / 17:43