}
// set pledge payment related fields
- $status = CRM_Utils_Request::retrieve('status', 'String',
- CRM_Core_DAO::$_nullObject
- );
+ $status = CRM_Utils_Request::retrieve('status', 'String');
if ($status) {
$this->_formValues['pledge_payment_status_id'] = array($status => 1);
$this->_defaults['pledge_payment_status_id'] = array($status => 1);
}
- $fromDate = CRM_Utils_Request::retrieve('start', 'Date',
- CRM_Core_DAO::$_nullObject
- );
+ $fromDate = CRM_Utils_Request::retrieve('start', 'Date');
if ($fromDate) {
list($date) = CRM_Utils_Date::setDateDefaults($fromDate);
$this->_formValues['pledge_payment_date_low'] = $date;
$this->_defaults['pledge_payment_date_low'] = $date;
}
- $toDate = CRM_Utils_Request::retrieve('end', 'Date',
- CRM_Core_DAO::$_nullObject
- );
+ $toDate = CRM_Utils_Request::retrieve('end', 'Date');
if ($toDate) {
list($date) = CRM_Utils_Date::setDateDefaults($toDate);
$this->_formValues['pledge_payment_date_high'] = $date;
}
// set pledge related fields
- $pledgeStatus = CRM_Utils_Request::retrieve('pstatus', 'String',
- CRM_Core_DAO::$_nullObject
- );
+ $pledgeStatus = CRM_Utils_Request::retrieve('pstatus', 'String');
if ($pledgeStatus) {
$statusValues = CRM_Contribute_PseudoConstant::contributionStatus();
class CRM_Pledge_Page_DashBoard extends CRM_Core_Page {
/**
- * Heart of the viewing process: The runner gets all the meta data for
- * the contact and calls the appropriate type of page to view.
+ * Heart of the viewing process.
+ *
+ * The runner gets all the meta data for the contact and calls the appropriate type of page to view.
*/
public function preProcess() {
CRM_Utils_System::setTitle(ts('CiviPledge'));
$startDateEnd = NULL;
// current year - prefix = 'year'
- $config = CRM_Core_Config::singleton();
- $yearDate = $config->fiscalYearStart;
+ $yearDate = \Civi::settings()->get('fiscalYearStart');
$year = array('Y' => date('Y'));
$this->assign('curYear', $year['Y']);
$yearDate = array_merge($year, $yearDate);
}
/**
- * the main function that is called when the page loads,
+ * The main function that is called when the page loads.
+ *
* it decides which action has to be taken for the page.
*
* @return null