lib/traits/elements.php
protected function setParamsFilters()
    {
        if ($this->arParams['IBLOCK_TYPE'])
        {
            $this->filterParams['IBLOCK_TYPE'] = $this->arParams['IBLOCK_TYPE'];
        }

        if ($this->arParams['IBLOCK_ID'])
        {
            $this->filterParams['IBLOCK_ID'] = $this->arParams['IBLOCK_ID'];
        }

        if ($this->arParams['SECTION_CODE'])
        {
            $this->filterParams['SECTION_CODE'] = $this->arParams['SECTION_CODE'];
        }
        elseif ($this->arParams['SECTION_ID'])
        {
            $this->filterParams['SECTION_ID'] = $this->arParams['SECTION_ID'];
        }

        if ($this->arParams['INCLUDE_SUBSECTIONS'] === 'Y')
        {
            $this->filterParams['INCLUDE_SUBSECTIONS'] = 'Y';
        }

        if ($this->arParams['ELEMENT_CODE'])
        {
            $this->filterParams['CODE'] = $this->arParams['ELEMENT_CODE'];
        }
        elseif ($this->arParams['ELEMENT_ID'])
        {
            $this->filterParams['ID'] = $this->arParams['ELEMENT_ID'];
        }

        if ($this->arParams['CHECK_PERMISSIONS'])
        {
            $this->filterParams['CHECK_PERMISSIONS'] = $this->arParams['CHECK_PERMISSIONS'];
        }

        if (!isset($this->filterParams['ACTIVE']))
        {
            $this->filterParams['ACTIVE'] = 'Y';
        }

        if (strlen($this->arParams['EX_FILTER_NAME']) > 0
            && preg_match("/^[A-Za-z_][A-Za-z01-9_]*$/", $this->arParams['EX_FILTER_NAME'])
            && is_array($GLOBALS[$this->arParams['EX_FILTER_NAME']])
        )
        {
            $this->filterParams = array_merge_recursive($this->filterParams, $GLOBALS[$this->arParams['EX_FILTER_NAME']]);

            $this->addCacheAdditionalId($GLOBALS[$this->arParams['EX_FILTER_NAME']]);
        }
    }
protected function setParamsFilters()
    {
        if ($this->arParams['IBLOCK_TYPE'])
        {
            $this->filterParams['IBLOCK_TYPE'] = $this->arParams['IBLOCK_TYPE'];
        }

        if ($this->arParams['IBLOCK_ID'])
        {
            $this->filterParams['IBLOCK_ID'] = $this->arParams['IBLOCK_ID'];
        }

        if ($this->arParams['SECTION_CODE'])
        {
            $this->filterParams['SECTION_CODE'] = $this->arParams['SECTION_CODE'];
        }
        elseif ($this->arParams['SECTION_ID'])
        {
            $this->filterParams['SECTION_ID'] = $this->arParams['SECTION_ID'];
        }

        if ($this->arParams['INCLUDE_SUBSECTIONS'] === 'Y')
        {
            $this->filterParams['INCLUDE_SUBSECTIONS'] = 'Y';
        }

        if ($this->arParams['ELEMENT_CODE'])
        {
            $this->filterParams['CODE'] = $this->arParams['ELEMENT_CODE'];
        }
        elseif ($this->arParams['ELEMENT_ID'])
        {
            $this->filterParams['ID'] = $this->arParams['ELEMENT_ID'];
        }

        if ($this->arParams['CHECK_PERMISSIONS'])
        {
            $this->filterParams['CHECK_PERMISSIONS'] = $this->arParams['CHECK_PERMISSIONS'];
        }

        if (!isset($this->filterParams['ACTIVE']))
        {
            $this->filterParams['ACTIVE'] = 'Y';
        }

        if (strlen($this->arParams['EX_FILTER_NAME']) > 0
            && preg_match("/^[A-Za-z_][A-Za-z01-9_]*$/", $this->arParams['EX_FILTER_NAME'])
            && is_array($GLOBALS[$this->arParams['EX_FILTER_NAME']])
        )
        {
            $this->filterParams = array_merge_recursive($this->filterParams, $GLOBALS[$this->arParams['EX_FILTER_NAME']]);

            $this->addCacheAdditionalId($GLOBALS[$this->arParams['EX_FILTER_NAME']]);
        }
    }
protected function setParamsFilters ( ) { if ( $ this -> arParams [ 'IBLOCK_TYPE' ] ) { $ this -> filterParams [ 'IBLOCK_TYPE' ] = $ this -> arParams [ 'IBLOCK_TYPE' ] ; } if ( $ this -> arParams [ 'IBLOCK_ID' ] ) { $ this -> filterParams [ 'IBLOCK_ID' ] = $ this -> arParams [ 'IBLOCK_ID' ] ; } if ( $ this -> arParams [ 'SECTION_CODE' ] ) { $ this -> filterParams [ 'SECTION_CODE' ] = $ this -> arParams [ 'SECTION_CODE' ] ; } elseif ( $ this -> arParams [ 'SECTION_ID' ] ) { $ this -> filterParams [ 'SECTION_ID' ] = $ this -> arParams [ 'SECTION_ID' ] ; } if ( $ this -> arParams [ 'INCLUDE_SUBSECTIONS' ] === 'Y' ) { $ this -> filterParams [ 'INCLUDE_SUBSECTIONS' ] = 'Y' ; } if ( $ this -> arParams [ 'ELEMENT_CODE' ] ) { $ this -> filterParams [ 'CODE' ] = $ this -> arParams [ 'ELEMENT_CODE' ] ; } elseif ( $ this -> arParams [ 'ELEMENT_ID' ] ) { $ this -> filterParams [ 'ID' ] = $ this -> arParams [ 'ELEMENT_ID' ] ; } if ( $ this -> arParams [ 'CHECK_PERMISSIONS' ] ) { $ this -> filterParams [ 'CHECK_PERMISSIONS' ] = $ this -> arParams [ 'CHECK_PERMISSIONS' ] ; } if ( ! isset ( $ this -> filterParams [ 'ACTIVE' ] ) ) { $ this -> filterParams [ 'ACTIVE' ] = 'Y' ; } if ( strlen ( $ this -> arParams [ 'EX_FILTER_NAME' ] ) > 0 && preg_match ( "/^[A-Za-z_][A-Za-z01-9_]*$/" , $ this -> arParams [ 'EX_FILTER_NAME' ] ) && is_array ( $ GLOBALS [ $ this -> arParams [ 'EX_FILTER_NAME' ] ] ) ) { $ this -> filterParams = array_merge_recursive ( $ this -> filterParams , $ GLOBALS [ $ this -> arParams [ 'EX_FILTER_NAME' ] ] ) ; $ this -> addCacheAdditionalId ( $ GLOBALS [ $ this -> arParams [ 'EX_FILTER_NAME' ] ] ) ; } }
Getting global filter and write his to component parameters
Getting global filter and write his to component parameters