CRM-10672 Add Open and Clickthru info about Bulk Email Activities

    Details

    • Type: Improvement
    • Status: Done/Fixed
    • Priority: Minor
    • Resolution: Fixed/Completed
    • Affects Version/s: 4.1.5
    • Fix Version/s: 4.3.0
    • Component/s: CiviMail

      Description

      When viewing an activity ( civicrm/activity/view? ..... ) , the information now included is basic. For Bulk Email type activities, it makes sense to include click-through and open rate information about this contact for this particular mailing.

      Another place where additional information about open- and click-through information would be useful is on the contact record's Activities tab. I <a href ='http://wiki.civicrm.org/confluence/display/CRMDOC41/Customizing+the+Activities+subtab+of+the+View+Contact+pages+using+template+files'>described how to add a column to this page in the wiki</a>
      http://wiki.civicrm.org/confluence/display/CRMDOC41/Customizing+the+Activities+subtab+of+the+View+Contact+pages+using+template+files

      ... but the was really focused on how to add a column with X information.

      I realized that CRM_Mailing_Event_BAO_Opened::getRows and CRM_Mailing_Event_BAO_TrackableURLOpen:getRows were very close to returning the query result I sought. I added contact_id as an argument and in the WHERE clause in these two functions. Combining this with the instructions in the wiki article above can improve the information on the view activity pages for bulk emails.

      I am packaging these changes together into a patch file. If the Powers That B are so inclined, these can be incorporated into a future release. If not, no big deal, this patch can still be applied to custom templates and custom php directories.

      Files affected are:
      CRM/Activity/BAO/Activity.php
      CRM/Mailling/Event/BAO/Opened.php
      CRM/Mailing/Event/BAO/TrackableURLOpen.php
      CRM/Activity/Form/ActivityView.php
      CRM/Activity/Page/AJAX.php

      and
      templates/CRM/Activity/Form/ActivityView.tpl

        Attachments

        1. activities-tab1.png
          44 kB
          Jim Earl
        2. Civi-4.1.5-bulk_email_stats.patch
          8 kB
          Jim Earl
        3. view-activity2.png
          128 kB
          Jim Earl

          Activity

          [CRM-10672] Add Open and Clickthru info about Bulk Email Activities
          Jim Earl added a comment -

          In purple is the information added to the View Activity page by this patch.

          Jim Earl added a comment -

          Attached image shows the changes (new column in purple) to the Activities tab of each contact. the information is how many times the user opened, or clicked a link in, a bulk email.

          Jim Earl added a comment -

          One other file gets altered: templates/CRM/Activity/Selector/Selector.tpl

          Jim Earl added a comment -

          Here is the patch, against 4.1.5, that will do this

          Coleman Watts added a comment -

          Thank you for your patch!

            People

            • Assignee:
              Coleman Watts
              Reporter:
              Jim Earl

              Dates

              • Created:
                Updated:
                Resolved:

                Time Tracking

                Estimated:
                Original Estimate - 1 hour
                1h
                Remaining:
                Time Spent - 30 minutes Remaining Estimate - 30 minutes
                30m
                Logged:
                Time Spent - 30 minutes Remaining Estimate - 30 minutes
                30m