From: francescbassas Date: Wed, 3 May 2017 18:46:57 +0000 (+0200) Subject: CRM-20518 Default participant status not set when status name not matches localized... X-Git-Url: https://vcs.fsf.org/?a=commitdiff_plain;h=e46598666059f288c669f3335950179a4e32fa96;p=civicrm-core.git CRM-20518 Default participant status not set when status name not matches localized string 'Registered' --- diff --git a/CRM/Event/Form/Participant.php b/CRM/Event/Form/Participant.php index 49b1c13bef..144122ab17 100644 --- a/CRM/Event/Form/Participant.php +++ b/CRM/Event/Form/Participant.php @@ -477,8 +477,8 @@ class CRM_Event_Form_Participant extends CRM_Contribute_Form_AbstractEditPayment //setting default register date if ($this->_action == CRM_Core_Action::ADD) { - $statuses = array_flip($this->_participantStatuses); - $defaults[$this->_id]['status_id'] = CRM_Utils_Array::value(ts('Registered'), $statuses); + $statuses = array_flip(CRM_Event_PseudoConstant::participantStatus()); + $defaults[$this->_id]['status_id'] = CRM_Utils_Array::value('Registered', $statuses); if (!empty($defaults[$this->_id]['event_id'])) { $contributionTypeId = CRM_Core_DAO::getFieldValue('CRM_Event_DAO_Event', $defaults[$this->_id]['event_id'],