Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Save flayder/256b3b3e7f9f3d229f5cfcd2bda9e2b1 to your computer and use it in GitHub Desktop.
Save flayder/256b3b3e7f9f3d229f5cfcd2bda9e2b1 to your computer and use it in GitHub Desktop.
use Bitrix\Iblock\Component\ElementList;
$filterDataValues['iblockId'] = "={$_REQUEST["ID"]}";
$arComponentParameters['PARAMETERS']['CUSTOM_FILTER'] = array(
'PARENT' => 'DATA_SOURCE',
'NAME' => GetMessage('CP_BCS_TPL_CUSTOM_FILTER'),
'TYPE' => 'CUSTOM',
'JS_FILE' => ElementList::getSettingsScript($componentPath, 'filter_conditions'),
'JS_EVENT' => 'initFilterConditionsControl',
'JS_MESSAGES' => Json::encode(array(
'invalid' => GetMessage('CP_BCS_TPL_SETTINGS_INVALID_CONDITION')
)),
'JS_DATA' => Json::encode($filterDataValues),
'DEFAULT' => ''
);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment