Type: New Feature
Affects Version/s: 2.0
Fix Version/s: 2.0
Based on the new features proposed for 2.0, we expect to need to modify the schema.
New fields for civicrm_volunteer_project:
- campaign_id (don't really like the idea of adding a campaign_id field to the volunteer table, but it's beyond the scope of our project to refactor all existing entities to use a lookup table instead)
- location_block_id - Will allow associating projects with a location directly (as opposed to relying on a associated entity like an event)
New table civicrm_volunteer_project_contact will manage relationships between projects and contacts. civicrm_volunteer_project.target_contact_id will be migrated to this table, which will support multiple types of beneficiaries (not just beneficiary). Field spec:
- id - CiviCRM gets mad if tables don't have id columns (e.g., the standard delete API requires the ID of the row to be deleted)
- project_id - FK to civicrm_volunteer_project
- contact_id - FK to civicrm_contact
- relationship_type_id - pseudo-FK to user-configurable option group named volunteer_project_relationship. Out of the box we'll have these three reserved types: volunteer_owner, volunteer_manager, volunteer_beneficiary.
These changes will need to be accounted for in both install and upgrade scripts, and the upgrade scripts will need to handle related data migrations.