Needs review
Project:
CiviNode And Civinode CCK
Version:
5.x-1.2
Component:
Code
Priority:
Normal
Category:
Feature request
Assigned:
Unassigned
Reporter:
Created:
28 Jul 2008 at 11:07 UTC
Updated:
17 Oct 2008 at 09:09 UTC
Jump to comment: Most recent file
Comments
Comment #1
bigjim commentedany idea if you are going to make this a separate module?
also, know what it would take to port it to D6/CiviCRM2.1?
Comment #2
joachim commentedThe file as it stands is a separate module, but as far as making it a separate project, I think it might be best to include it with civinode if the maintainer agrees and it's compatible.
I've no plans to port it to D6/Civi 2.1.
Comment #3
bigjim commentedCool, thanks for responding
I ran it through coder last night doesn't look like there is much to change, I'll see if I can get it going on D6/C2.1 and post my results here.
Comment #4
joachim commentedThe CiviCRM API may have changed -- they ripped out quite a bit of functionality for 2.0 and may have made further changes for 2.1.
Comment #5
bigjim commentedI changed a little, but for the most part your code worked flawlessly,
Besides updates to Drupal hooks (hook_theme, hook_node_access, and hook_menu) and updates to the info and install files I changed two things. In the code calls to civicrm_groups_get() are now civicrm_group_get(), not sure if that is an api change or not. Also, the form_values array changed so $form_state['checkboxes'] is now $form_state['values']['checkboxes'], line 185 in the original code.
I've attached the files here, it is tested and works on
Drupal 6.5
CiviCRM 2.1 beta6
I need the list of fields to be configurable by a client without going into module file and allow them to use custom fields. Hence, I'm going to change the ways the the list of fields appears to allow users to change available fields. Going to try getting the list of available fields from a profile.
I'll post that code back here as a patch.
Comment #6
joachim commented> I need the list of fields to be configurable by a client without going into module file and allow them to use custom fields. Hence, I'm going to change the ways the the list of fields appears to allow users to change available fields. Going to try getting the list of available fields from a profile.
I'd suggest you make an admin page for the module, where you provide checkboxes for all those fields, and store the array currently hardcoded in _civi_organization_node_civi_fields as a drupal variable.