When use the search-task to register event participants, the qfKey is
mismatched, and the action is VIEW. It should be ADD, and the qfKey
should be for CRM_Event_Form_Participant.
//set ajax path, this used for custom data building
$this->assign('urlPath', 'civicrm/contact/view/participant');
- $this->assign('urlPathVar', "_qf_Participant_display=true&qfKey={$this->controller->_key}");
+
+ $key = CRM_Core_Key::get('CRM_Event_Form_Participant', TRUE);
+ $this->assign('participantQfKey', $key);
+ $this->assign('participantAction', CRM_Core_Action::ADD);
+ $this->assign('urlPathVar', "_qf_Participant_display=true");
}
}
$controller = new CRM_Core_Controller_Simple(
'CRM_Event_Form_Participant',
'Create Participation',
- $this->_action, FALSE, FALSE, TRUE
+ $this->_action
);
$controller->setEmbedded(TRUE);
| and copyright information, see https://civicrm.org/licensing |
+--------------------------------------------------------------------+
*}
-{include file="CRM/Event/Form/Participant.tpl"}
+{crmScope qfKey=$participantQfKey action=$participantAction}
+ {include file="CRM/Event/Form/Participant.tpl"}
+{/crmScope}