X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=CRM%2FReport%2FForm%2FContribute%2FSybunt.php;h=fcb778f592f6fc8cb19187ab5469d85b13f84f91;hb=973535196eeb576136587c194710bc648df9946c;hp=259943fa1ff8f08f09b3b26445cfadd7422d698e;hpb=37d5fc559ee587efb96bcf05721448c2c2e3cd57;p=civicrm-core.git diff --git a/CRM/Report/Form/Contribute/Sybunt.php b/CRM/Report/Form/Contribute/Sybunt.php index 259943fa1f..fcb778f592 100644 --- a/CRM/Report/Form/Contribute/Sybunt.php +++ b/CRM/Report/Form/Contribute/Sybunt.php @@ -1,9 +1,9 @@ - array( - 'dao' => 'CRM_Contact_DAO_GroupContact', - 'alias' => 'cgroup', - 'filters' => - array( - 'gid' => - array( - 'name' => 'group_id', - 'title' => ts('Group'), - 'operatorType' => CRM_Report_Form::OP_MULTISELECT, - 'group' => TRUE, - 'options' => CRM_Core_PseudoConstant::group(), - ), - ), - ), ); // If we have a campaign, build out the relevant elements @@ -200,6 +190,7 @@ class CRM_Report_Form_Contribute_Sybunt extends CRM_Report_Form { ); } + $this->_groupFilter = TRUE; $this->_tagFilter = TRUE; parent::__construct(); } @@ -261,7 +252,7 @@ class CRM_Report_Form_Contribute_Sybunt extends CRM_Report_Form { function from() { - $this->_from = " + $this->_from = " FROM civicrm_contribution {$this->_aliases['civicrm_contribution']} INNER JOIN civicrm_contact {$this->_aliases['civicrm_contact']} ON {$this->_aliases['civicrm_contact']}.id = {$this->_aliases['civicrm_contribution']}.contact_id @@ -337,6 +328,11 @@ class CRM_Report_Form_Contribute_Sybunt extends CRM_Report_Form { $this->_groupBy = "Group BY {$this->_aliases['civicrm_contribution']}.contact_id, " . self::fiscalYearOffset($this->_aliases['civicrm_contribution'] . '.receive_date') . " WITH ROLLUP "; } + /** + * @param $rows + * + * @return array + */ function statistics(&$rows) { $statistics = parent::statistics($rows); @@ -436,6 +432,9 @@ class CRM_Report_Form_Contribute_Sybunt extends CRM_Report_Form { $this->endPostProcess($rows); } + /** + * @param $rows + */ function buildChart(&$rows) { $graphRows = array(); $count = 0; @@ -471,6 +470,9 @@ class CRM_Report_Form_Contribute_Sybunt extends CRM_Report_Form { } } + /** + * @param $rows + */ function alterDisplay(&$rows) { // custom code to alter rows $entryFound = FALSE; @@ -508,6 +510,12 @@ class CRM_Report_Form_Contribute_Sybunt extends CRM_Report_Form { } // Override "This Year" $op options + /** + * @param string $type + * @param null $fieldName + * + * @return array + */ function getOperationPair($type = "string", $fieldName = NULL) { if ($fieldName == 'yid') { return array('calendar' => ts('Is Calendar Year'), 'fiscal' => ts('Fiscal Year Starting'));