----------------------------------------
* CRM-14937: CiviEvents: when using existing location on a new event, only the first phone number is loaded causing data loss on save
https://issues.civicrm.org/jira/browse/CRM-14937
$this->_id = CRM_Utils_Request::retrieve('id', 'Positive', $this, FALSE, NULL, 'GET');
if ($this->_id) {
$this->assign('eventId', $this->_id);
- if (empty($this->_addProfileBottom) && empty($this->_addProfileBottomAdd)) {
+ if (!empty($this->_addBlockName) && empty($this->_addProfileBottom) && empty($this->_addProfileBottomAdd)) {
$this->add('hidden', 'id', $this->_id);
}
$this->_single = TRUE;
* @access public
*/
function preProcess() {
- //location blocks.
- CRM_Contact_Form_Location::preProcess($this);
-
- //skip rest of postpress when we are building additional email and phone blocks
- if (!empty($this->_addBlockName)) {
- return;
- }
-
parent::preProcess();
$this->_values = $this->get('values');
if ($this->_id && empty($this->_values)) {
-
//get location values.
$params = array(
'entity_id' => $this->_id,
CRM_Event_BAO_Event::retrieve($params, $this->_values);
$this->set('values', $this->_values);
}
+
+ //location blocks.
+ CRM_Contact_Form_Location::preProcess($this);
}
/**