X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=CRM%2FEvent%2FSelector%2FSearch.php;h=a983983642b4b407854461a4b2d0d2d5f475c180;hb=2da40d216d22a8f768c53921644d040667a1713e;hp=21a61abb840876ecad68a502e6ff6a4cfe541d96;hpb=ddca8f33d73a8d22b70b84d596b1e3ad95e6949d;p=civicrm-core.git diff --git a/CRM/Event/Selector/Search.php b/CRM/Event/Selector/Search.php index 21a61abb84..a983983642 100644 --- a/CRM/Event/Selector/Search.php +++ b/CRM/Event/Selector/Search.php @@ -23,7 +23,7 @@ | GNU Affero General Public License or the licensing of CiviCRM, | | see the CiviCRM license FAQ at http://civicrm.org/licensing | +--------------------------------------------------------------------+ -*/ + */ /** * @@ -45,7 +45,6 @@ class CRM_Event_Selector_Search extends CRM_Core_Selector_Base implements CRM_Co * This defines two actions- View and Edit. * * @var array - * @static */ static $_links = NULL; @@ -53,14 +52,12 @@ class CRM_Event_Selector_Search extends CRM_Core_Selector_Base implements CRM_Co * We use desc to remind us what that column is, name is used in the tpl * * @var array - * @static */ static $_columnHeaders; /** * Properties of contact we're interested in displaying * @var array - * @static */ static $_properties = array( 'contact_id', @@ -159,9 +156,8 @@ class CRM_Event_Selector_Search extends CRM_Core_Selector_Base implements CRM_Co * @param null $compContext * * @return \CRM_Event_Selector_Search - @access public */ - function __construct( + public function __construct( &$queryParams, $action = CRM_Core_Action::NONE, $eventClause = NULL, @@ -173,9 +169,9 @@ class CRM_Event_Selector_Search extends CRM_Core_Selector_Base implements CRM_Co // submitted form values $this->_queryParams = &$queryParams; - $this->_single = $single; - $this->_limit = $limit; - $this->_context = $context; + $this->_single = $single; + $this->_limit = $limit; + $this->_context = $context; $this->_compContext = $compContext; $this->_eventClause = $eventClause; @@ -199,7 +195,6 @@ class CRM_Event_Selector_Search extends CRM_Core_Selector_Base implements CRM_Co * * @param int $limit * How many participations do we want returned. - * */ public function setLimit($limit) { $this->_limit = $limit; @@ -261,7 +256,6 @@ class CRM_Event_Selector_Search extends CRM_Core_Selector_Base implements CRM_Co * * @param $action * @param array $params - * */ public function getPagerParams($action, &$params) { $params['status'] = ts('Event') . ' %%StatusMessage%%'; @@ -282,7 +276,8 @@ class CRM_Event_Selector_Search extends CRM_Core_Selector_Base implements CRM_Co * * @param * - * @return int Total number of rows + * @return int + * Total number of rows */ public function getTotalCount($action) { return $this->_query->searchQuery(0, 0, NULL, @@ -296,7 +291,7 @@ class CRM_Event_Selector_Search extends CRM_Core_Selector_Base implements CRM_Co /** * Returns all the rows in the given offset and rowCount * - * @param enum $action + * @param string $action * The action being performed. * @param int $offset * The row number to start from. @@ -304,10 +299,11 @@ class CRM_Event_Selector_Search extends CRM_Core_Selector_Base implements CRM_Co * The number of rows to return. * @param string $sort * The sql string that describes the sort order. - * @param enum $output + * @param string $output * What should the result set include (web/email/csv). * - * @return array rows in the given offset and rowCount + * @return array + * rows in the given offset and rowCount */ public function &getRows($action, $offset, $rowCount, $sort, $output = NULL) { $result = $this->_query->searchQuery($offset, $rowCount, $sort, @@ -329,10 +325,10 @@ class CRM_Event_Selector_Search extends CRM_Core_Selector_Base implements CRM_Co } $mask = CRM_Core_Action::mask($permissions); - $statusTypes = CRM_Event_PseudoConstant::participantStatus(); - $statusClasses = CRM_Event_PseudoConstant::participantStatusClass(); + $statusTypes = CRM_Event_PseudoConstant::participantStatus(); + $statusClasses = CRM_Event_PseudoConstant::participantStatusClass(); $participantRoles = CRM_Event_PseudoConstant::participantRole(); - $sep = CRM_Core_DAO::VALUE_SEPARATOR; + $sep = CRM_Core_DAO::VALUE_SEPARATOR; //get all campaigns. $allCampaigns = CRM_Campaign_BAO_Campaign::getCampaigns(NULL, NULL, FALSE, FALSE, FALSE, TRUE); @@ -428,10 +424,7 @@ class CRM_Event_Selector_Search extends CRM_Core_Selector_Base implements CRM_Co } /** - * FIXME: the current internationalisation is bad, but should more or less work - * on most of "European" languages - * - * @return array $qill which contains an array of strings + * @inheritDoc */ public function getQILL() { return $this->_query->qill(); @@ -443,16 +436,17 @@ class CRM_Event_Selector_Search extends CRM_Core_Selector_Base implements CRM_Co * * @param string $action * The action being performed. - * @param enum $output + * @param string $output * What should the result set include (web/email/csv). * - * @return array the column headers that need to be displayed + * @return array + * the column headers that need to be displayed */ public function &getColumnHeaders($action = NULL, $output = NULL) { if (!isset(self::$_columnHeaders)) { self::$_columnHeaders = array( array( - 'name' => ts('Event'), + 'name' => ts('Event'), 'sort' => 'event_title', 'direction' => CRM_Utils_Sort::DONTCARE, ), @@ -524,9 +518,11 @@ class CRM_Event_Selector_Search extends CRM_Core_Selector_Base implements CRM_Co * @param string $output * Type of output. * - * @return string name of the file + * @return string + * name of the file */ public function getExportFileName($output = 'csv') { return ts('CiviCRM Event Search'); } + }