// Search field metadata is normally added in buildForm but we are bypassing that in this flow
// (I've always found the flow kinda confusing & perhaps that is the problem but this mitigates)
$this->addSearchFieldMetadata(['Contribution' => CRM_Contribute_BAO_Query::getSearchFieldMetadata()]);
+ $this->addSearchFieldMetadata(['ContributionRecur' => CRM_Contribute_BAO_ContributionRecur::getContributionRecurSearchFieldMetadata()]);
$this->postProcess();
$this->set('force', 0);
}
CRM_Core_Error::deprecatedFunctionWarning('pass receive_date_high not end');
}
$this->_defaults = parent::setDefaultValues();
+
+ $this->_defaults = array_merge($this->getEntityDefaults('ContributionRecur'), $this->_defaults);
+
if (empty($this->_defaults['contribution_status_id']) && !$this->_force) {
// In force mode only parameters from the url will be used. When visible/ explicit this is a useful default.
$this->_defaults['contribution_status_id'][1] = CRM_Core_PseudoConstant::getKey(
$this->_done = TRUE;
- if (!empty($_POST) && !$this->_force) {
- $this->_formValues = $this->controller->exportValues($this->_name);
- }
- $this->convertTextStringsToUseLikeOperator();
+ $this->setFormValues();
$this->fixFormValues();
// We don't show test records in summaries or dashboards
if (!$this->_force) {
return;
}
- // Start by loading url defaults.
- $this->_formValues = $this->setDefaultValues();
$status = CRM_Utils_Request::retrieve('status', 'String');
if ($status) {