Merge pull request #4899 from colemanw/INFRA-132
[civicrm-core.git] / CRM / Pledge / BAO / Query.php
index 138301ef1ae8bab081f57b0b68a2ffa51dca5190..273e59e4659b8b42c56183992318e37a409100d4 100644 (file)
@@ -48,7 +48,6 @@ class CRM_Pledge_BAO_Query {
    * @param $query
    *
    * @return void
-   * @access public
    */
   public static function select(&$query) {
     if (($query->_mode & CRM_Contact_BAO_Query::MODE_PLEDGE) || !empty($query->_returnProperties['pledge_id'])) {
@@ -103,7 +102,7 @@ class CRM_Pledge_BAO_Query {
     }
 
     if (!empty($query->_returnProperties['pledge_financial_type'])) {
-      $query->_select['pledge_financial_type']  = "(SELECT civicrm_financial_type.name FROM civicrm_financial_type WHERE civicrm_financial_type.id = civicrm_pledge.financial_type_id) as pledge_financial_type";
+      $query->_select['pledge_financial_type'] = "(SELECT civicrm_financial_type.name FROM civicrm_financial_type WHERE civicrm_financial_type.id = civicrm_pledge.financial_type_id) as pledge_financial_type";
       $query->_element['pledge_financial_type'] = 1;
       $query->_tables['civicrm_pledge'] = $query->_whereTables['civicrm_pledge'] = 1;
     }
@@ -295,7 +294,7 @@ class CRM_Pledge_BAO_Query {
           }
         }
         else {
-          if (!empty($value) ) {
+          if (!empty($value)) {
             $names[] = $statusValues[$value];
           }
         }
@@ -337,7 +336,7 @@ class CRM_Pledge_BAO_Query {
           }
         }
         else {
-          if (!empty($value) ) {
+          if (!empty($value)) {
             $names[] = $statusValues[$value];
           }
         }
@@ -374,7 +373,7 @@ class CRM_Pledge_BAO_Query {
           $value,
           'Integer'
         );
-            $query->_qill[$grouping][] = ts( 'Financial Type - %1', array( 1 => $type ) );
+        $query->_qill[$grouping][] = ts('Financial Type - %1', array(1 => $type));
         $query->_tables['civicrm_pledge'] = $query->_whereTables['civicrm_pledge'] = 1;
         return;
 
@@ -441,7 +440,7 @@ class CRM_Pledge_BAO_Query {
         break;
 
       case 'pledge_financial_type':
-            $from .= " $side JOIN civicrm_financial_type ON civicrm_pledge.financial_type_id = civicrm_financial_type.id ";
+        $from .= " $side JOIN civicrm_financial_type ON civicrm_pledge.financial_type_id = civicrm_financial_type.id ";
         break;
 
       case 'civicrm_pledge_payment':
@@ -465,7 +464,6 @@ class CRM_Pledge_BAO_Query {
    * Getter for the qill object
    *
    * @return string
-   * @access public
    */
   public function qill() {
     return (isset($this->_qill)) ? $this->_qill : "";
@@ -474,7 +472,8 @@ class CRM_Pledge_BAO_Query {
   /**
    * Ideally this function should include fields that are displayed in the selector
    */
-  static function defaultReturnProperties($mode,
+  static function defaultReturnProperties(
+    $mode,
     $includeCustomFields = TRUE
   ) {
     $properties = NULL;
@@ -576,7 +575,7 @@ class CRM_Pledge_BAO_Query {
     $form->addGroup($paymentStatus, 'pledge_payment_status_id', ts('Pledge Payment Status'));
 
     $form->add('select', 'pledge_financial_type_id',
-      ts( 'Financial Type' ),
+      ts('Financial Type'),
       array('' => ts('- select -')) + CRM_Contribute_PseudoConstant::financialType(),
       FALSE, array('class' => 'crm-select2')
     );
@@ -628,7 +627,8 @@ class CRM_Pledge_BAO_Query {
    * @param $row
    * @param int $id
    */
-  public static function searchAction(&$row, $id) {}
+  public static function searchAction(&$row, $id) {
+  }
 
   /**
    * @param $tables
@@ -640,4 +640,3 @@ class CRM_Pledge_BAO_Query {
     }
   }
 }
-