$this->set('type', 'Activity');
$this->set('subType', $this->_activityTypeId);
$this->set('entityId', $this->_activityId);
- CRM_Custom_Form_CustomData::preProcess($this);
+ CRM_Custom_Form_CustomData::preProcess($this, NULL, $this->_activityTypeId, 1, 'Activity', $this->_activityId);
CRM_Custom_Form_CustomData::buildQuickForm($this);
CRM_Custom_Form_CustomData::setDefaultValues($this);
}
// when custom data is included in form.
if (!empty($_POST['hidden_custom'])) {
+ $campaignTypeId = empty($_POST['campaign_type_id']) ? NULL : $_POST['campaign_type_id'];
$this->set('type', 'Campaign');
- $this->set('subType', CRM_Utils_Array::value('campaign_type_id', $_POST));
+ $this->set('subType', $campaignTypeId);
$this->set('entityId', $this->_campaignId);
- CRM_Custom_Form_CustomData::preProcess($this);
+ CRM_Custom_Form_CustomData::preProcess($this, NULL, $campaignTypeId, 1, 'Campaign', $this->_campaignId);
CRM_Custom_Form_CustomData::buildQuickForm($this);
CRM_Custom_Form_CustomData::setDefaultValues($this);
}
// when custom data is included in this page
if (!empty($_POST['hidden_custom'])) {
+ $grantTypeId = empty($_POST['grant_type_id']) ? NULL : $_POST['grant_type_id'];
$this->set('type', 'Grant');
- $this->set('subType', CRM_Utils_Array::value('grant_type_id', $_POST));
+ $this->set('subType', $grantTypeId);
$this->set('entityId', $this->_id);
- CRM_Custom_Form_CustomData::preProcess($this);
+ CRM_Custom_Form_CustomData::preProcess($this, NULL, $grantTypeId, 1, 'Grant', $this->_id);
CRM_Custom_Form_CustomData::buildQuickForm($this);
CRM_Custom_Form_CustomData::setDefaultValues($this);
}
// when custom data is included in this page
if (!empty($_POST['hidden_custom'])) {
- CRM_Custom_Form_CustomData::preProcess($this);
+ CRM_Custom_Form_CustomData::preProcess($this, NULL, $this->_memType, 1, 'Membership', $this->_id);
CRM_Custom_Form_CustomData::buildQuickForm($this);
CRM_Custom_Form_CustomData::setDefaultValues($this);
}