From 0179fdce8a52b5cc7931c337213645e81f15a72d Mon Sep 17 00:00:00 2001 From: monishdeb Date: Fri, 18 Sep 2015 19:14:57 +0530 Subject: [PATCH] notice and format fixes --- CRM/Report/Form.php | 4 ++-- CRM/Report/Form/Event/ParticipantListCount.php | 9 ++++----- 2 files changed, 6 insertions(+), 7 deletions(-) diff --git a/CRM/Report/Form.php b/CRM/Report/Form.php index 84129769d2..af72c422ec 100644 --- a/CRM/Report/Form.php +++ b/CRM/Report/Form.php @@ -2683,8 +2683,8 @@ WHERE cg.extends IN ('" . implode("','", $this->_customGroupExtends) . "') AND */ public function groupBy() { $groupBys = array(); - if (is_array($this->_params['group_bys']) && - !empty($this->_params['group_bys']) + if (!empty($this->_params['group_bys']) && + is_array($this->_params['group_bys']) ) { foreach ($this->_columns as $tableName => $table) { if (array_key_exists('group_bys', $table)) { diff --git a/CRM/Report/Form/Event/ParticipantListCount.php b/CRM/Report/Form/Event/ParticipantListCount.php index 98fc91d949..9eb0ec4efe 100644 --- a/CRM/Report/Form/Event/ParticipantListCount.php +++ b/CRM/Report/Form/Event/ParticipantListCount.php @@ -465,13 +465,12 @@ class CRM_Report_Form_Event_ParticipantListCount extends CRM_Report_Form_Event { $this->_whereClauses[] = "{$this->_aliases['civicrm_participant']}.is_test = 0"; } - // We override this function because we use GROUP functions in the - // SELECT clause, therefore we have to group by *something*. If the - // user doesn't select a column to group by, we should group by - // participant id. public function groupBy() { + // We override this function because we use GROUP functions in the + // SELECT clause, therefore we have to group by *something*. If the + // user doesn't select a column to group by, we should group by participant id. parent::groupBy(); - if(empty($this->_groupBy)) { + if (empty($this->_groupBy)) { $this->_groupBy = "GROUP BY {$this->_aliases['civicrm_participant']}.id"; } } -- 2.25.1