X-Git-Url: https://vcs.fsf.org/?a=blobdiff_plain;f=CRM%2FEvent%2FPseudoConstant.php;h=feaa604bedcca030d915afac84dd2dfaa79459d9;hb=0ea79a6887c97d6682437c9432b708982631da60;hp=39536722add33c66de1a9f6b5a52a87692c84596;hpb=e3a363809875b227257e2247d43ed96115817c65;p=civicrm-core.git diff --git a/CRM/Event/PseudoConstant.php b/CRM/Event/PseudoConstant.php index 39536722ad..feaa604bed 100644 --- a/CRM/Event/PseudoConstant.php +++ b/CRM/Event/PseudoConstant.php @@ -1,9 +1,9 @@ ts('Positive'), + 'Pending' => ts('Pending'), + 'Waiting' => ts('Waiting'), + 'Negative' => ts('Negative'), + ); + } + /** * Return a status-type-keyed array of status classes * - * @return array of status classes, keyed by status type + * @return array + * Array of status classes, keyed by status type */ - static function &participantStatusClass() { + public static function &participantStatusClass() { static $statusClasses = NULL; if ($statusClasses === NULL) { @@ -181,15 +187,14 @@ class CRM_Event_PseudoConstant extends CRM_Core_PseudoConstant { } /** - * Get all the n participant roles + * Get all the n participant roles. * - * @access public * - * @param null $id + * @param int $id * @param null $cond * - * @return array - array reference of all participant roles if any - * @static + * @return array + * array reference of all participant roles if any */ public static function &participantRole($id = NULL, $cond = NULL) { $index = $cond ? $cond : 'No Condition'; @@ -214,14 +219,13 @@ class CRM_Event_PseudoConstant extends CRM_Core_PseudoConstant { } /** - * Get all the participant listings + * Get all the participant listings. * - * @access public * - * @param null $id + * @param int $id * - * @return array - array reference of all participant listings if any - * @static + * @return array + * array reference of all participant listings if any */ public static function &participantListing($id = NULL) { if (!self::$participantListing) { @@ -239,11 +243,10 @@ class CRM_Event_PseudoConstant extends CRM_Core_PseudoConstant { /** * Get all event types. * - * @access public * - * @param null $id - * @return array - array reference of all event types. - * @static + * @param int $id + * @return array + * array reference of all event types. */ public static function &eventType($id = NULL) { if (!self::$eventType) { @@ -259,11 +262,12 @@ class CRM_Event_PseudoConstant extends CRM_Core_PseudoConstant { } /** - * get event template titles + * Get event template titles. * - * @param null $id + * @param int $id * - * @return array of event id → template title pairs + * @return array + * Array of event id → template title pairs */ public static function &eventTemplates($id = NULL) { if (!self::$eventTemplates) { @@ -285,25 +289,22 @@ class CRM_Event_PseudoConstant extends CRM_Core_PseudoConstant { * Flush given pseudoconstant so it can be reread from db * nex time it's requested. * - * @access public - * @static * * @param bool|string $name pseudoconstant to be flushed */ public static function flush($name = 'cache') { - if (isset(self::$$name)) { + if (isset(self::$$name)) { self::$$name = NULL; } } /** - * Get all the Personal campaign pages + * Get all the Personal campaign pages. * - * @access public * - * @param null $id - * @return array - array reference of all pcp if any - * @static + * @param int $id + * @return array + * array reference of all pcp if any */ public static function &pcPage($id = NULL) { if (!self::$pcPage) { @@ -317,5 +318,5 @@ class CRM_Event_PseudoConstant extends CRM_Core_PseudoConstant { } return self::$pcPage; } -} +}