From 53f568807bfe32f35ab302f3cad63c56eb8b8b55 Mon Sep 17 00:00:00 2001 From: Sudha Bisht Date: Wed, 6 May 2015 14:46:09 +0530 Subject: [PATCH] Fix for contribution time --- CRM/Event/Form/EventFees.php | 4 ++-- CRM/Event/Form/Participant.php | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/CRM/Event/Form/EventFees.php b/CRM/Event/Form/EventFees.php index 6eb0b51ad7..0fe1414044 100644 --- a/CRM/Event/Form/EventFees.php +++ b/CRM/Event/Form/EventFees.php @@ -117,7 +117,7 @@ class CRM_Event_Form_EventFees { $defaults[$form->_pId]['receipt_text'] = $details[$form->_eventId]['confirm_email_text']; } - list($defaults[$form->_pId]['receive_date']) = CRM_Utils_Date::setDateDefaults(); + list($defaults[$form->_pId]['receive_date'], $defaults[$form->_pId]['receive_date_time']) = CRM_Utils_Date::setDateDefaults(); } //CRM-11601 we should keep the record contribution @@ -423,7 +423,7 @@ SELECT id, html_type array('' => ts('- select -')) + CRM_Contribute_PseudoConstant::financialType() ); - $form->addDate('receive_date', ts('Received'), FALSE, array('formatType' => 'activityDate')); + $form->addDateTime('receive_date', ts('Received'), FALSE, array('formatType' => 'activityDateTime')); $form->add('select', 'payment_instrument_id', ts('Paid By'), diff --git a/CRM/Event/Form/Participant.php b/CRM/Event/Form/Participant.php index f740dd7a32..3afc3d1820 100644 --- a/CRM/Event/Form/Participant.php +++ b/CRM/Event/Form/Participant.php @@ -1050,7 +1050,7 @@ class CRM_Event_Form_Participant extends CRM_Contribute_Form_AbstractEditPayment unset($params['amount']); } $params['register_date'] = CRM_Utils_Date::processDate($params['register_date'], $params['register_date_time']); - $params['receive_date'] = CRM_Utils_Date::processDate(CRM_Utils_Array::value('receive_date', $params)); + $params['receive_date'] = CRM_Utils_Date::processDate(CRM_Utils_Array::value('receive_date', $params), CRM_Utils_Array::value('receive_date_time', $params)); $params['contact_id'] = $this->_contactId; // overwrite actual payment amount if entered -- 2.25.1