From 9e40c4169aa0a84ccb7c2e0bcf97d243d066e0e3 Mon Sep 17 00:00:00 2001 From: sushantpaste Date: Fri, 24 May 2019 17:20:48 +0530 Subject: [PATCH] dev/core#877 Fixes alterReportVars hook invoke --- CRM/Report/Form.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/CRM/Report/Form.php b/CRM/Report/Form.php index 8e36623d68..88d4d93ac3 100644 --- a/CRM/Report/Form.php +++ b/CRM/Report/Form.php @@ -2377,12 +2377,6 @@ WHERE cg.extends IN ('" . implode("','", $this->_customGroupExtends) . "') AND } } - // build array of section totals - $this->sectionTotals(); - - // process grand-total row - $this->grandTotal($rows); - // Find alter display functions. $firstRow = reset($rows); if ($firstRow) { @@ -2423,6 +2417,12 @@ WHERE cg.extends IN ('" . implode("','", $this->_customGroupExtends) . "') AND $this->alterDisplay($rows); CRM_Utils_Hook::alterReportVar('rows', $rows, $this); + // build array of section totals + $this->sectionTotals(); + + // process grand-total row + $this->grandTotal($rows); + // use this method for formatting custom rows for display purpose. $this->alterCustomDataDisplay($rows); } -- 2.25.1