Add deprecation comments, CRM-19987
[civicrm-core.git] / CRM / Activity / BAO / Activity.php
index 48893a169fb072809dccba80e88d0e8c8123d5da..52d192476f731b3abf6d7382a8565a42251e7bb3 100644 (file)
@@ -3,7 +3,7 @@
  +--------------------------------------------------------------------+
  | CiviCRM version 4.7                                                |
  +--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2016                                |
+ | Copyright CiviCRM LLC (c) 2004-2017                                |
  +--------------------------------------------------------------------+
  | This file is a part of CiviCRM.                                    |
  |                                                                    |
@@ -28,7 +28,7 @@
 /**
  *
  * @package CRM
- * @copyright CiviCRM LLC (c) 2004-2016
+ * @copyright CiviCRM LLC (c) 2004-2017
  */
 
 /**
@@ -1705,6 +1705,8 @@ LEFT JOIN civicrm_activity_contact src ON (src.activity_id = ac.activity_id AND
   }
 
   /**
+   * @deprecated - use the api instead.
+   *
    * Get the Activities of a target contact.
    *
    * @param int $contactId
@@ -1714,6 +1716,7 @@ LEFT JOIN civicrm_activity_contact src ON (src.activity_id = ac.activity_id AND
    *   array of activity fields
    */
   public static function getContactActivity($contactId) {
+    // @todo remove this function entirely.
     $activities = array();
     $activityContacts = CRM_Core_OptionGroup::values('activity_contacts', FALSE, FALSE, FALSE, NULL, 'name');
     $sourceID = CRM_Utils_Array::key('Activity Source', $activityContacts);
@@ -2175,6 +2178,12 @@ AND cl.modified_id  = c.id
             'type' => CRM_Utils_Type::T_STRING,
             'searchByLabel' => TRUE,
           ),
+          'activity_priority' => array(
+            'title' => ts('Activity Priority'),
+            'name' => 'activity_priority',
+            'type' => CRM_Utils_Type::T_STRING,
+            'searchByLabel' => TRUE,
+          ),
         );
         $fields = array_merge($Activityfields, $exportableFields);
       }