Merge pull request #9448 from civicrm/4.7.14-rc
[civicrm-core.git] / CRM / Member / Task.php
index bb28abbe3ce55798123bc2fd7e2e228fab136ded..5470390e5b817b513347f3f9aa6b2423a37dddbc 100644 (file)
@@ -1,9 +1,9 @@
 <?php
 /*
  +--------------------------------------------------------------------+
- | CiviCRM version 4.6                                                |
+ | CiviCRM version 4.7                                                |
  +--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2014                                |
+ | Copyright CiviCRM LLC (c) 2004-2016                                |
  +--------------------------------------------------------------------+
  | This file is a part of CiviCRM.                                    |
  |                                                                    |
  | GNU Affero General Public License or the licensing of CiviCRM,     |
  | see the CiviCRM license FAQ at http://civicrm.org/licensing        |
  +--------------------------------------------------------------------+
-*/
+ */
 
 /**
  *
  * @package CRM
- * @copyright CiviCRM LLC (c) 2004-2014
+ * @copyright CiviCRM LLC (c) 2004-2016
  * $Id$
  *
  */
@@ -46,7 +46,6 @@ class CRM_Member_Task {
    * The task array
    *
    * @var array
-   * @static
    */
   static $_tasks = NULL;
 
@@ -54,7 +53,6 @@ class CRM_Member_Task {
    * The optional task array
    *
    * @var array
-   * @static
    */
   static $_optionalTasks = NULL;
 
@@ -62,24 +60,24 @@ class CRM_Member_Task {
    * These tasks are the core set of tasks that the user can perform
    * on a contact / group of contacts
    *
-   * @return array the set of tasks for a group of contacts
-   * @static
+   * @return array
+   *   the set of tasks for a group of contacts
    */
   public static function &tasks() {
     if (!(self::$_tasks)) {
       self::$_tasks = array(
         1 => array(
-          'title' => ts('Delete Memberships'),
+          'title' => ts('Delete memberships'),
           'class' => 'CRM_Member_Form_Task_Delete',
           'result' => FALSE,
         ),
         2 => array(
-          'title' => ts('Print Selected Rows'),
+          'title' => ts('Print selected rows'),
           'class' => 'CRM_Member_Form_Task_Print',
           'result' => FALSE,
         ),
         3 => array(
-          'title' => ts('Export Members'),
+          'title' => ts('Export members'),
           'class' => array(
             'CRM_Export_Form_Select',
             'CRM_Export_Form_Map',
@@ -87,12 +85,12 @@ class CRM_Member_Task {
           'result' => FALSE,
         ),
         4 => array(
-          'title' => ts('Send Email to Contacts'),
+          'title' => ts('Email - send now'),
           'class' => 'CRM_Member_Form_Task_Email',
           'result' => TRUE,
         ),
         5 => array(
-          'title' => ts('Batch Update Members Via Profile'),
+          'title' => ts('Update multiple memberships'),
           'class' => array(
             'CRM_Member_Form_Task_PickProfile',
             'CRM_Member_Form_Task_Batch',
@@ -100,14 +98,14 @@ class CRM_Member_Task {
           'result' => TRUE,
         ),
         6 => array(
-          'title' => ts('Mailing Labels'),
+          'title' => ts('Mailing labels - print'),
           'class' => array(
             'CRM_Member_Form_Task_Label',
           ),
           'result' => TRUE,
         ),
         7 => array(
-          'title' => ts('Print PDF Letters for Memberships'),
+          'title' => ts('Print/merge document for memberships'),
           'class' => 'CRM_Member_Form_Task_PDFLetter',
           'result' => FALSE,
         ),
@@ -118,7 +116,7 @@ class CRM_Member_Task {
         unset(self::$_tasks[1]);
       }
       //CRM-12920 - check for edit permission
-      if( !CRM_Core_Permission::check('edit memberships') ){
+      if (!CRM_Core_Permission::check('edit memberships')) {
         unset(self::$_tasks[5]);
       }
     }
@@ -131,8 +129,8 @@ class CRM_Member_Task {
    * These tasks are the core set of task titles
    * on members
    *
-   * @return array the set of task titles
-   * @static
+   * @return array
+   *   the set of task titles
    */
   public static function &taskTitles() {
     self::tasks();
@@ -149,7 +147,8 @@ class CRM_Member_Task {
    *
    * @param int $permission
    *
-   * @return array set of tasks that are valid for the user
+   * @return array
+   *   set of tasks that are valid for the user
    */
   public static function &permissionedTaskTitles($permission) {
     $tasks = array();
@@ -177,8 +176,8 @@ class CRM_Member_Task {
    *
    * @param int $value
    *
-   * @return array the set of tasks for a group of members
-   * @static
+   * @return array
+   *   the set of tasks for a group of members
    */
   public static function getTask($value) {
     self::tasks();
@@ -191,4 +190,5 @@ class CRM_Member_Task {
       self::$_tasks[$value]['result'],
     );
   }
+
 }