Merge pull request #5060 from eileenmcnaughton/api-comment-fixes
[civicrm-core.git] / CRM / Contribute / Selector / Search.php
index 26f99824403554ae5f6f6c609ee73b5978af3cff..ed22579c57b9bd8e4853903fbfae977ce286f82d 100644 (file)
@@ -23,7 +23,7 @@
  | GNU Affero General Public License or the licensing of CiviCRM,     |
  | see the CiviCRM license FAQ at http://civicrm.org/licensing        |
  +--------------------------------------------------------------------+
-*/
+ */
 
 /**
  *
@@ -45,7 +45,6 @@ class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
    * This defines two actions- View and Edit.
    *
    * @var array
-   * @static
    */
   static $_links = NULL;
 
@@ -53,14 +52,12 @@ class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
    * We use desc to remind us what that column is, name is used in the tpl
    *
    * @var array
-   * @static
    */
   static $_columnHeaders;
 
   /**
    * Properties of contact we're interested in displaying
    * @var array
-   * @static
    */
   static $_properties = array(
     'contact_id',
@@ -165,9 +162,8 @@ class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
    * @param null $compContext
    *
    * @return \CRM_Contribute_Selector_Search
-   * @access public
    */
-  function __construct(
+  public function __construct(
     &$queryParams,
     $action = CRM_Core_Action::NONE,
     $contributionClause = NULL,
@@ -284,7 +280,7 @@ class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
   /**
    * Returns total number of rows for the query.
    *
-   * @param
+   * @param string $action
    *
    * @return int
    *   Total number of rows
@@ -455,8 +451,8 @@ class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
       ),
     );
     if ($this->_includeSoftCredits) {
-      self::$_columnHeaders =
-        array_merge(
+      self::$_columnHeaders
+        array_merge(
           self::$_columnHeaders,
           array(
             array(
@@ -467,8 +463,8 @@ class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
           )
         );
     }
-    self::$_columnHeaders =
-      array_merge(
+    self::$_columnHeaders
+      array_merge(
         self::$_columnHeaders,
         array(
           array(
@@ -515,25 +511,24 @@ class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
       self::$_columnHeaders = array_merge($pre, self::$_columnHeaders);
     }
     if ($this->_includeSoftCredits) {
-      self::$_columnHeaders =
-        array_merge(
-          self::$_columnHeaders,
+      self::$_columnHeaders = array_merge(
+        self::$_columnHeaders,
+        array(
           array(
-            array(
-              'name' => ts('Soft Credit For'),
-              'sort' => 'contribution_soft_credit_name',
-              'direction' => CRM_Utils_Sort::DONTCARE,
-            ),
-            array(
-              'name' => ts('Soft Credit Type'),
-              'sort' => 'contribution_soft_credit_type',
-              'direction' => CRM_Utils_Sort::ASCENDING,
-            ),
-          )
-        );
+            'name' => ts('Soft Credit For'),
+            'sort' => 'contribution_soft_credit_name',
+            'direction' => CRM_Utils_Sort::DONTCARE,
+          ),
+          array(
+            'name' => ts('Soft Credit Type'),
+            'sort' => 'contribution_soft_credit_type',
+            'direction' => CRM_Utils_Sort::ASCENDING,
+          ),
+        )
+      );
     }
-    self::$_columnHeaders =
-      array_merge(
+    self::$_columnHeaders
+      array_merge(
         self::$_columnHeaders, array(
           array('desc' => ts('Actions')),
         )
@@ -574,4 +569,5 @@ class CRM_Contribute_Selector_Search extends CRM_Core_Selector_Base implements C
   public function getSummary() {
     return $this->_query->summaryContribution($this->_context);
   }
+
 }