}
}
- // set db value of filter in params if filter is non editable
- if ($this->_id && !array_key_exists('filter', $params) && !$this->_gName == 'participant_role') {
- $params['filter'] = CRM_Core_DAO::getFieldValue('CRM_Core_DAO_OptionValue', $this->_id, 'filter', 'id');
+ // set value of filter if not present in params
+ if ($this->_id && !array_key_exists('filter', $params)) {
+ if ($this->_gName == 'participant_role') {
+ $params['filter'] = 0;
+ } else {
+ $params['filter'] = CRM_Core_DAO::getFieldValue('CRM_Core_DAO_OptionValue', $this->_id, 'filter', 'id');
+ }
}
$groupParams = array('name' => ($this->_gName));