Skip to content
Snippets Groups Projects
Commit af72b8c7 authored by pratik.joshi's avatar pratik.joshi
Browse files

crm-10164 : more fixes

parent e4d8474f
Branches
Tags
No related merge requests found
......@@ -85,7 +85,6 @@ class CRM_Event_Form_Registration_Confirm extends CRM_Event_Form_Registration {
$this->assign('hookDiscount', $this->_params[0]['discount']);
}
$config = CRM_Core_Config::singleton();
if ($this->_contributeMode == 'express') {
$params = array();
// rfp == redirect from paypal
......@@ -278,11 +277,6 @@ class CRM_Event_Form_Registration_Confirm extends CRM_Event_Form_Registration {
$this->set('totalAmount', $this->_totalAmount);
}
$config = CRM_Core_Config::singleton();
//$this->buildCustom($this->_values['custom_pre_id'], 'customPre', TRUE);
//$this->buildCustom($this->_values['custom_post_id'], 'customPost', TRUE);
if ($this->_priceSetId && !CRM_Core_DAO::getFieldValue('CRM_Price_DAO_Set', $this->_priceSetId, 'is_quick_config')) {
$lineItemForTemplate = array();
foreach ($this->_lineItem as $key => $value) {
......@@ -455,8 +449,7 @@ class CRM_Event_Form_Registration_Confirm extends CRM_Event_Form_Registration {
*/
public function postProcess() {
$now = date('YmdHis');
$config = CRM_Core_Config::singleton();
$session = CRM_Core_Session::singleton();
$this->_params = $this->get('params');
if (CRM_Utils_Array::value('contact_id', $this->_params[0])) {
$contactID = $this->_params[0]['contact_id'];
......@@ -564,6 +557,7 @@ class CRM_Event_Form_Registration_Confirm extends CRM_Event_Form_Registration {
// transactions etc
// for things like tell a friend
if (!$this->getContactID() && CRM_Utils_Array::value('is_primary', $value)) {
$session = CRM_Core_Session::singleton();
$session->set('transaction.userID', $contactID);
}
......@@ -894,7 +888,6 @@ class CRM_Event_Form_Registration_Confirm extends CRM_Event_Form_Registration {
) {
$transaction = new CRM_Core_Transaction();
$config = CRM_Core_Config::singleton();
$now = date('YmdHis');
$receiptDate = NULL;
......
<?php
/*
+--------------------------------------------------------------------+
| CiviCRM version 4.3 |
| CiviCRM version 4.3 |
+--------------------------------------------------------------------+
| Copyright CiviCRM LLC (c) 2004-2013 |
+--------------------------------------------------------------------+
......@@ -56,7 +56,7 @@ class CRM_Event_Form_Registration_ParticipantConfirm extends CRM_Event_Form_Regi
//get the contact and event id and assing to session.
$values = array();
$csContactID = $eventId = NULL;
$csContactID = NULL;
if ($this->_participantId) {
$params = array('id' => $this->_participantId);
CRM_Core_DAO::commonRetrieve('CRM_Event_DAO_Participant', $params, $values,
......@@ -173,7 +173,6 @@ class CRM_Event_Form_Registration_ParticipantConfirm extends CRM_Event_Form_Regi
public function postProcess() {
//get the button.
$buttonName = $this->controller->getButtonName();
$eventId = $this->_eventId;
$participantId = $this->_participantId;
if ($buttonName == '_qf_ParticipantConfirm_next') {
......@@ -185,7 +184,7 @@ class CRM_Event_Form_Registration_ParticipantConfirm extends CRM_Event_Form_Regi
//check user registration status is from pending class
$url = CRM_Utils_System::url('civicrm/event/register',
"reset=1&id={$eventId}&participantId={$participantId}"
"reset=1&id={$this->_eventId}&participantId={$participantId}"
);
CRM_Utils_System::redirect($url);
}
......
......@@ -359,7 +359,6 @@ class CRM_Event_Form_Registration_Register extends CRM_Event_Form_Registration {
$this->assign('contact_id', $contactID);
$this->assign('display_name', CRM_Contact_BAO_Contact::displayName($contactID));
$config = CRM_Core_Config::singleton();
$this->add('hidden', 'scriptFee', NULL);
$this->add('hidden', 'scriptArray', NULL);
......@@ -858,7 +857,6 @@ class CRM_Event_Form_Registration_Register extends CRM_Event_Form_Registration {
}
}
// return if this is express mode
$config = CRM_Core_Config::singleton();
if ($self->_paymentProcessor &&
$self->_paymentProcessor['billing_mode'] & CRM_Core_Payment::BILLING_MODE_BUTTON
) {
......
......@@ -157,7 +157,6 @@ class CRM_Event_Form_Registration_ThankYou extends CRM_Event_Form_Registration {
$this->setDefaults($defaults);
$params['entity_id'] = $this->_eventId;
$params['entity_table'] = 'civicrm_event';
$data = array();
......@@ -192,15 +191,14 @@ class CRM_Event_Form_Registration_ThankYou extends CRM_Event_Form_Registration {
$this->assign('isRequireApproval', $isRequireApproval);
// find pcp info
$eventId = $this->_eventId;
$dao = new CRM_PCP_DAO_PCPBlock();
$dao->entity_table = 'civicrm_event';
$dao->entity_id = $eventId;
$dao->entity_id = $this->_eventId;
$dao->is_active = 1;
$dao->find(TRUE);
if ($dao->id) {
$this->assign('pcpLink', CRM_Utils_System::url('civicrm/contribute/campaign', 'action=add&reset=1&pageId=' . $eventId . '&component=event'));
$this->assign('pcpLink', CRM_Utils_System::url('civicrm/contribute/campaign', 'action=add&reset=1&pageId=' . $this->_eventId . '&component=event'));
$this->assign('pcpLinkText', $dao->link_text);
}
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment