<?php
/*
+--------------------------------------------------------------------+
- | CiviCRM version 4.4 |
+ | CiviCRM version 4.5 |
+--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2013 |
+ | Copyright CiviCRM LLC (c) 2004-2014 |
+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
/**
*
* @package CRM
- * @copyright CiviCRM LLC (c) 2004-2013
+ * @copyright CiviCRM LLC (c) 2004-2014
* $Id$
*
*/
$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;
}
}
+ /**
+ * @return string
+ */
function getTemplateFileName() {
if ($this->controller->getPrint() || $this->getVar('_id') <= 0 || $this->_action & CRM_Core_Action::DELETE) {
return parent::getTemplateFileName();
return 'CRM/Event/Form/ManageEvent/Tab.tpl';
}
}
+
+ /**
+ * Pre-load libraries required by Online Registration Profile fields
+ */
+ static function addProfileEditScripts() {
+ CRM_UF_Page_ProfileEditor::registerProfileScripts();
+ CRM_UF_Page_ProfileEditor::registerSchemas(array('IndividualModel', 'ParticipantModel'));
+ }
}