+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
// UI for selecting columns to appear in the report list
// array conatining the columns, group_bys and filters build and provided to Form
$this->_columns = array(
// UI for selecting columns to appear in the report list
// array conatining the columns, group_bys and filters build and provided to Form
$this->_columns = array(
- 'group_bys' =>
- array(
- 'id' =>
- array('title' => ts('Contact ID')),
- 'display_name' =>
- array('title' => ts('Contact Name'),
+ 'group_bys' => array(
+ 'id' => array('title' => ts('Contact ID')),
+ 'display_name' => array(
+ 'title' => ts('Contact Name'),
'dao' => 'CRM_Member_DAO_MembershipType',
'grouping' => 'member-fields',
'dao' => 'CRM_Member_DAO_MembershipType',
'grouping' => 'member-fields',
'name' => 'id',
'title' => ts('Membership Types'),
'type' => CRM_Utils_Type::T_INT + CRM_Utils_Type::T_ENUM,
'name' => 'id',
'title' => ts('Membership Types'),
'type' => CRM_Utils_Type::T_INT + CRM_Utils_Type::T_ENUM,
'dao' => 'CRM_Member_DAO_Membership',
'grouping' => 'member-fields',
'dao' => 'CRM_Member_DAO_Membership',
'grouping' => 'member-fields',
$select = array();
$this->_columnHeaders = array();
foreach ($this->_columns as $tableName => $table) {
if (array_key_exists('fields', $table)) {
foreach ($table['fields'] as $fieldName => $field) {
$select = array();
$this->_columnHeaders = array();
foreach ($this->_columns as $tableName => $table) {
if (array_key_exists('fields', $table)) {
foreach ($table['fields'] as $fieldName => $field) {
// to include optional columns address and email, only if checked
if ($tableName == 'civicrm_address') {
$this->_addressField = TRUE;
// to include optional columns address and email, only if checked
if ($tableName == 'civicrm_address') {
$this->_addressField = TRUE;
$clauses = array();
foreach ($this->_columns as $tableName => $table) {
if (array_key_exists('filters', $table)) {
$clauses = array();
foreach ($this->_columns as $tableName => $table) {
if (array_key_exists('filters', $table)) {
$clause = NULL;
if ($field['type'] & CRM_Utils_Type::T_DATE) {
$relative = CRM_Utils_Array::value("{$fieldName}_relative", $this->_params);
$clause = NULL;
if ($field['type'] & CRM_Utils_Type::T_DATE) {
$relative = CRM_Utils_Array::value("{$fieldName}_relative", $this->_params);
- $from = CRM_Utils_Array::value("{$fieldName}_from", $this->_params);
- $to = CRM_Utils_Array::value("{$fieldName}_to", $this->_params);
+ $from = CRM_Utils_Array::value("{$fieldName}_from", $this->_params);
+ $to = CRM_Utils_Array::value("{$fieldName}_to", $this->_params);
if ($relative || $from || $to) {
$clause = $this->dateClause($field['name'], $relative, $from, $to);
if ($relative || $from || $to) {
$clause = $this->dateClause($field['name'], $relative, $from, $to);