Page MenuHomePhabricator

Track which email people clicked to upgrade their recurring donation
Closed, ResolvedPublic

Description

Use wmf_medium and wmf_campaign parameters on the links, and pass them through on the upgrade or decline message to Civi.

Need to determine where to store them in Civi. Should we add custom fields to the activity table?

Event Timeline

Ejegg updated the task description. (Show Details)

In Tech Talk we just decided it's OK to add these as activity custom fields.

@JMando This is related to the thing that @MSuijkerbuijk_WMF just messaged you about in Slack - to track clicks from email for things that are not payments-wiki donation attempts, we need a new place to store the utm_ fields in CiviCRM. I think I'll call the new table civicrm_activity_tracking and name each field without the utm_ prefix (since we're moving to wmf_ prefixes in the front end), so:

civicrm_activity_tracking.medium
civicrm_activity_tracking.campaign

you can join civicrm_activity_tracking to civicrm_activity on civicrm_activity_tracking.entity_id = civicrm_activity.id

Change 1011009 had a related patch set uploaded (by Ejegg; author: Ejegg):

[wikimedia/fundraising/crm@master] Add custom fields for Activity tracking

https://gerrit.wikimedia.org/r/1011009

Change 1011014 had a related patch set uploaded (by Ejegg; author: Ejegg):

[mediawiki/extensions/DonationInterface@master] Add wmf_* tracking fields to RecurUpgrade message

https://gerrit.wikimedia.org/r/1011014

Change 1011019 had a related patch set uploaded (by Ejegg; author: Ejegg):

[wikimedia/fundraising/crm@master] Save Tracking fields for RecurUpgrade messages

https://gerrit.wikimedia.org/r/1011019

Change 1011014 merged by jenkins-bot:

[mediawiki/extensions/DonationInterface@master] Add wmf_* tracking fields to RecurUpgrade message

https://gerrit.wikimedia.org/r/1011014

Change 1011009 merged by jenkins-bot:

[wikimedia/fundraising/crm@master] Add custom fields for Activity tracking

https://gerrit.wikimedia.org/r/1011009

Change 1011019 merged by jenkins-bot:

[wikimedia/fundraising/crm@master] Save Tracking fields for RecurUpgrade messages

https://gerrit.wikimedia.org/r/1011019

This is deployed to track the wmf_ parameters when they accept the upgrade, but doesn't yet work to track the parameters when they decline the upgrade. I'll try to get that done tomorrow. Also still in the works: passing the parameters along to the TY page.

OK, I have deployed the fixes to track the parameters when they decline and to pass the parameters along to the TY pages.

XenoRyet set Final Story Points to 4.