Details
-
Type:
Sub-task
-
Status: Done/Fixed
-
Priority:
Major
-
Resolution: Fixed/Completed
-
Affects Version/s: 3.3.2
-
Fix Version/s: 3.4.alpha
-
Component/s: CiviCampaign, CiviContribute, CiviEvent, CiviMail, CiviMember, CiviPledge
-
Labels:None
Description
=========
1. Schema
=========
Add "campaign_id foreign key column to the following tables:
- civicrm_contribution_page
- civicrm_contribution
- civicrm_membership
- civicrm_pledge
- civicrm_event
- civicrm_participant
- civicrm_mailing
- civicrm_activity
Issues:
- do we need campaign_id in civicrm_pcp? Seems like the linked contribution page will carry the campaign, but ??
====================
2. Forms and View Pages
=====================
When CiviCampaign is enabled, add "Campaign" drop-down field to the following forms. Also add "Campaign" display field to the following pages IF campaign_id is NOT NULL for the record. I think we need
NOTE: If there are no Campaigns created, for the Create / Edit forms ... show the field label and then the following message status div instead of the dropdown form field:
"There are currently no Campaigns.
{if user has permission to add campaign}If you want to associate this record with a campaign, you can <a href="$addCampaignUrl">create a campaign here</a>.
{/if}"
- Add / Edit Activity (below "Subject") and View Activity
- Add / Edit Contribution (below "Source") and View Contribution
- Configure Contribution Page - Title and Settings (below "Contribution Type")
- Configure Event - Info and Settings (below "Event Type"), include in event template form as well.
- Add / Edit Participant (below "Event") and View Participant
- Mailing - Step 1 (select recipients) (below "Name Your Mailing")
- Add / Edit Membership (below "Source") and View Membership
- Add / Edit Pledge (below "Contribution Type") and View Pledge
Issues:
- I think folks will be creating time-delimited campaigns (with End Dates), and possibly using the "is_active" flag more with Campaigns then with some of our other objects. AND, they will want to search/report on past (and possibly inactive) campaigns, see linkages in contributions etc. We need to accommodate this w/o cluttering the default select lists. Suggest showing only active and current (end date >= now) campaigns by default for ADD mode on forms with a link to "show past campaigns". However in EDIT and VIEW modes, we need to be able to select / display the linked campaign regardless of whether it is current / active or not.
====================
3. Selectors (Listings)
====================
If CiviCampaign is enabled, add Campaign column to the following selectors:
- Manage Online Contribution Pages
- Manage Events
- Mailings (mailing/browse) - all modes
NOTE: For space reasons Activity, Contribution, Membership, Participant and Pledge selectors will not have the campaign column. However the selectors should return campaign id and campaign title for these SO a user can customize the template if needed
====================
4. Processing
====================
4.1 Campaign inherited from contribution page campaign property
If an online contribution page has a campaign_id, all contributions, pledges and memberships made via that page should inherit that campaign_id.
4.2 Campaign inherited from event campaign property
4.2.1 Online registrations: If an event has a campaign_id, all online registrations via this event registration form inherit the campaign_id.
4.2.2 Back-office registration (Participant form): when user selects Event, if the event has a configure campaign_id, then that becomes the default form value for the Campaign field. However, user can over-ride and select a different campaign if desired.
4.3 Campaign via GET parameter
Campaign ID can be passed in to event registration or online contribution pages via GET parameter. (&campID=N).
Issue:
If campID is passed to an event or contribution page that already has a configured campaign, the GET parameter should override the default IF the campID is a valid campaign
====================
5. Profiles
====================
Campaign should be exposed for use in Batch Update via Profile for the following objects (so users can batch update set or modify associated campaign):
- activity
- contribution
- membership
- participant
- Campaign fields in Profile Used for = Event Registration or Contribution Page.
Campaign fields are exposed as a SELECT element. The filter is only active campaigns which are currently valid (i.e. not over)