From db36f066e82a529facfb7412ea5c6c7bf34c0fdd Mon Sep 17 00:00:00 2001 From: Mathieu Lutfy Date: Mon, 9 May 2016 17:23:02 -0400 Subject: [PATCH] CRM-17997: Fix Sybunt year totals. --- CRM/Report/Form/Contribute/Sybunt.php | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/CRM/Report/Form/Contribute/Sybunt.php b/CRM/Report/Form/Contribute/Sybunt.php index 1625378f68..3d6655df15 100644 --- a/CRM/Report/Form/Contribute/Sybunt.php +++ b/CRM/Report/Form/Contribute/Sybunt.php @@ -283,14 +283,14 @@ class CRM_Report_Form_Contribute_Sybunt extends CRM_Report_Form { $this->_columnHeaders["civicrm_upto_{$upTo_year}"]['type'] = $field['type']; $this->_columnHeaders["civicrm_upto_{$upTo_year}"]['title'] = "Up To $upTo_year"; - $this->_columnHeaders["{$previous_ppyear}"]['type'] = $field['type']; - $this->_columnHeaders["{$previous_ppyear}"]['title'] = $previous_ppyear; + $this->_columnHeaders["year_{$previous_ppyear}"]['type'] = $field['type']; + $this->_columnHeaders["year_{$previous_ppyear}"]['title'] = $previous_ppyear; - $this->_columnHeaders["{$previous_pyear}"]['type'] = $field['type']; - $this->_columnHeaders["{$previous_pyear}"]['title'] = $previous_pyear; + $this->_columnHeaders["year_{$previous_pyear}"]['type'] = $field['type']; + $this->_columnHeaders["year_{$previous_pyear}"]['title'] = $previous_pyear; - $this->_columnHeaders["{$previous_year}"]['type'] = $field['type']; - $this->_columnHeaders["{$previous_year}"]['title'] = $previous_year; + $this->_columnHeaders["year_{$previous_year}"]['type'] = $field['type']; + $this->_columnHeaders["year_{$previous_year}"]['title'] = $previous_year; $this->_columnHeaders["civicrm_life_time_total"]['type'] = $field['type']; $this->_columnHeaders["civicrm_life_time_total"]['title'] = 'LifeTime';; @@ -484,7 +484,7 @@ class CRM_Report_Form_Contribute_Sybunt extends CRM_Report_Form { if ($dao->civicrm_contribution_receive_date) { if ($dao->civicrm_contribution_receive_date > $upTo_year) { $contributionSum += $dao->civicrm_contribution_total_amount; - $rows[$dao->civicrm_contribution_contact_id][$dao->civicrm_contribution_receive_date] = $dao->civicrm_contribution_total_amount; + $rows[$dao->civicrm_contribution_contact_id]['year_' . $dao->civicrm_contribution_receive_date] = $dao->civicrm_contribution_total_amount; } } else { -- 2.25.1