CRM_Contact_Page_View_CustomData::run() calls CRM_Profile_Page_MultipleRecordFieldsListing::run(). The latter function currently only assigns customGroupId to the tpl if the limit of rows to display has not been reached.
However, if the var is a required parameter for the ajax call that follow
s and without it the page does not render. There is no clue as to why it
is wrapped in the if and changing it does
not cause problems in the follow on ajax call
CRM_Custom_Page_AJAX::getMultiRecordFieldList
The only other place this is called from is
CRM_Profile_Form::preProcess when
mode is not EDIT and gid is set
elseif ($this->_pageViewType == 'customDataView') {
// require custom group id for _pageViewType of customDataView
$customGroupId = $this->_customGroupId;
+ $this->assign('customGroupId', $customGroupId);
$reached = CRM_Core_BAO_CustomGroup::hasReachedMaxLimit($customGroupId, $this->_contactId);
if (!$reached) {
$this->assign('contactId', $this->_contactId);
- $this->assign('customGroupId', $customGroupId);
$this->assign('ctype', $this->_contactType);
}
$this->assign('reachedMax', $reached);