Classes/Configuration/RecordRenderingConfigurationBuilder.php
protected function resolveTableNameAndUidFromContextString(string $contextRecord)
    {
        if ($contextRecord === 'currentPage') {
            $tableNameAndUid = ['pages', $this->renderingContext->getFrontendController()->id];
        } else {
            $tableNameAndUid = explode(':', $contextRecord);
            if (count($tableNameAndUid) !== 2 || empty($tableNameAndUid[0]) || empty($tableNameAndUid[1]) || !MathUtility::canBeInterpretedAsInteger($tableNameAndUid[1])) {
                $tableNameAndUid = ['pages', $this->renderingContext->getFrontendController()->id];
            }
        }
        // TODO: maybe check if the record is available
        return $tableNameAndUid;
    }
protected function resolveTableNameAndUidFromContextString(string $contextRecord)
    {
        if ($contextRecord === 'currentPage') {
            $tableNameAndUid = ['pages', $this->renderingContext->getFrontendController()->id];
        } else {
            $tableNameAndUid = explode(':', $contextRecord);
            if (count($tableNameAndUid) !== 2 || empty($tableNameAndUid[0]) || empty($tableNameAndUid[1]) || !MathUtility::canBeInterpretedAsInteger($tableNameAndUid[1])) {
                $tableNameAndUid = ['pages', $this->renderingContext->getFrontendController()->id];
            }
        }
        // TODO: maybe check if the record is available
        return $tableNameAndUid;
    }
protected function resolveTableNameAndUidFromContextString ( string $ contextRecord ) { if ( $ contextRecord === 'currentPage' ) { $ tableNameAndUid = [ 'pages' , $ this -> renderingContext -> getFrontendController ( ) -> id ] ; } else { $ tableNameAndUid = explode ( ':' , $ contextRecord ) ; if ( count ( $ tableNameAndUid ) !== 2 || empty ( $ tableNameAndUid [ 0 ] ) || empty ( $ tableNameAndUid [ 1 ] ) || ! MathUtility :: canBeInterpretedAsInteger ( $ tableNameAndUid [ 1 ] ) ) { $ tableNameAndUid = [ 'pages' , $ this -> renderingContext -> getFrontendController ( ) -> id ] ; } } // TODO: maybe check if the record is available return $ tableNameAndUid ; }
Resolves the table name and uid for the record the rendering is based upon.
Falls back to current page if none is available

@param string $contextRecord

@return string[] table name as first and uid as second index of the array
Resolves the table name and uid for the record the rendering is based upon . Falls back to current page if none is available