0

我的 Flexform 配置不显示。我认为 ext_tables.php 中的所有内容都是错误的。

也许路径(pluginSignature)有问题?

defined('TYPO3_MODE') || die('Access denied.');

call_user_func(
function()
{
    // Build extension name vars - used for plugin registration, flexforms and similar
    $extensionName = \TYPO3\CMS\Core\Utility\GeneralUtility::underscoredToUpperCamelCase($_EXTKEY);
    $pluginSignature = strtolower($extensionName) . '_operationsstatistics';

    \TYPO3\CMS\Extbase\Utility\ExtensionUtility::registerPlugin(
        'FfwLohfelden.OperationsStatistics',
        'Operationsstatistics',
        'Operations Statistics'
    );

    \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addStaticFile('operations_statistics', 'Configuration/TypoScript', 'Operations Statistics');

    \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addLLrefForTCAdescr('tx_operationsstatistics_domain_model_statistic', 'EXT:operations_statistics/Resources/Private/Language/locallang_csh_tx_operationsstatistics_domain_model_statistic.xlf');
    \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::allowTableOnStandardPages('tx_operationsstatistics_domain_model_statistic');

    $GLOBALS['TCA']['tt_content']['types']['list']['subtypes_excludelist'][$pluginSignature] = 'layout,select_key,pages,recursive';
    $GLOBALS['TCA']['tt_content']['types']['list']['subtypes_addlist'][$pluginSignature] = 'pi_flexform';
    \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addPiFlexFormValue($pluginSignature,
        'FILE:EXT:' . $_EXTKEY . '/Configuration/FlexForm/flexform_list.xml');

}
);
4

1 回答 1

0

您可以在 ext_tables.php 文件中尝试以下配置。

//extenstion name
$extensionName = \TYPO3\CMS\Core\Utility\GeneralUtility::underscoredToUpperCamelCase($_EXTKEY);

//plugin integration
$frontendpluginName = 'plugin name';
$pluginSignature = strtolower($extensionName) . '_'.strtolower(
    $frontendpluginName
);

$GLOBALS['TCA']['tt_content']['types']['list']['subtypes_addlist'][$pluginSignature] = 'pi_flexform';
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addPiFlexFormValue(
    $pluginSignature,
    'FILE:EXT:' . $_EXTKEY . '/Configuration/FlexForms/configure.xml'
);
于 2018-06-07T06:56:02.303 回答