X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=CRM%2FContact%2FForm%2FSearch%2FCustom%2FContributionAggregate.php;h=244b4c6d8d6aa7cc545898cb26845c01b4076b5c;hb=546b78fa6081abf7d1185636d38b278c11cc843a;hp=9b608900ccd984be26f3a7c3c7184c414cf6baf2;hpb=e9aca61e8b08d5ae372621c4397108b8f2ec28ba;p=civicrm-core.git diff --git a/CRM/Contact/Form/Search/Custom/ContributionAggregate.php b/CRM/Contact/Form/Search/Custom/ContributionAggregate.php index 9b608900cc..244b4c6d8d 100644 --- a/CRM/Contact/Form/Search/Custom/ContributionAggregate.php +++ b/CRM/Contact/Form/Search/Custom/ContributionAggregate.php @@ -42,10 +42,8 @@ class CRM_Contact_Form_Search_Custom_ContributionAggregate implements CRM_Contac */ public function __construct(&$formValues) { $this->_formValues = $formValues; - /** - * Define the columns for search result rows - */ + // Define the columns for search result rows $this->_columns = array( ts('Contact ID') => 'contact_id', ts('Name') => 'sort_name', @@ -86,7 +84,7 @@ class CRM_Contact_Form_Search_Custom_ContributionAggregate implements CRM_Contac $form->addDate('end_date', ts('...through'), FALSE, array('formatType' => 'custom')); $financial_types = CRM_Contribute_PseudoConstant::financialType(); - foreach($financial_types as $financial_type_id => $financial_type) { + foreach ($financial_types as $financial_type_id => $financial_type) { $form->addElement('checkbox', "financial_type_id[{$financial_type_id}]", 'Financial Type', $financial_type); } @@ -99,6 +97,8 @@ class CRM_Contact_Form_Search_Custom_ContributionAggregate implements CRM_Contac /** * Define the smarty template used to layout the search form and results listings. + * + * @return string */ public function templateFile() { return 'CRM/Contact/Form/Search/Custom/ContributionAggregate.tpl'; @@ -106,8 +106,17 @@ class CRM_Contact_Form_Search_Custom_ContributionAggregate implements CRM_Contac /** * Construct the search query + * + * @param int $offset + * @param int $rowcount + * @param string|object $sort + * @param bool $includeContactIDs + * @param bool $justIDs + * + * @return string */ - function all($offset = 0, $rowcount = 0, $sort = NULL, + function all( + $offset = 0, $rowcount = 0, $sort = NULL, $includeContactIDs = FALSE, $justIDs = FALSE ) { @@ -174,11 +183,9 @@ civicrm_contact AS contact_a "; } - /* - * WHERE clause is an array built from any required JOINS plus conditional filters based on search criteria field values - * - */ /** + * WHERE clause is an array built from any required JOINS plus conditional filters based on search criteria field values + * * @param bool $includeContactIDs * * @return string @@ -248,6 +255,10 @@ civicrm_contact AS contact_a /* * Functions below generally don't need to be modified */ + + /** + * @inheritDoc + */ public function count() { $sql = $this->all();