<?php
/*
+--------------------------------------------------------------------+
- | CiviCRM version 4.7 |
+ | CiviCRM version 5 |
+--------------------------------------------------------------------+
| Copyright CiviCRM LLC (c) 2004-2018 |
+--------------------------------------------------------------------+
ON {$this->_aliases['civicrm_contact']}.id = {$this->_aliases['civicrm_contribution']}.contact_id
{$this->_aclFrom}";
- if ($this->isTableSelected('civicrm_email')) {
- $this->_from .= "
- LEFT JOIN civicrm_email {$this->_aliases['civicrm_email']}
- ON {$this->_aliases['civicrm_contact']}.id = {$this->_aliases['civicrm_email']}.contact_id
- AND {$this->_aliases['civicrm_email']}.is_primary = 1";
- }
- if ($this->isTableSelected('civicrm_phone')) {
- $this->_from .= "
- LEFT JOIN civicrm_phone {$this->_aliases['civicrm_phone']}
- ON {$this->_aliases['civicrm_contact']}.id = {$this->_aliases['civicrm_phone']}.contact_id AND
- {$this->_aliases['civicrm_phone']}.is_primary = 1";
- }
+ $this->joinPhoneFromContact();
+ $this->joinEmailFromContact();
+
// for credit card type
$this->addFinancialTrxnFromClause();
- $this->addAddressFromClause();
+ $this->joinAddressFromContact();
}
public function where() {
$graphRows['value'] = $display;
$config = CRM_Core_Config::Singleton();
$chartInfo = array(
- 'legend' => 'Sybunt Report',
- 'xname' => 'Year',
- 'yname' => "Amount ({$config->defaultCurrency})",
+ 'legend' => ts('Sybunt Report'),
+ 'xname' => ts('Year'),
+ 'yname' => ts('Amount (%1)', array(1 => $config->defaultCurrency)),
);
if ($this->_params['charts']) {
// build the chart.