cobwebch / external_import

Other
20 stars 16 forks source link

LocalizationUtility::translate(): Argument #1 ($key) must be of type string, null given #299

Closed linawolf closed 1 year ago

linawolf commented 1 year ago

TYPO3 v12.4.6: I get the following error on opening a record in the backend module, even though the table exists and has a a title:

(1/1) TypeError
TYPO3\CMS\Extbase\Utility\LocalizationUtility::translate(): Argument #1 ($key) must be of type string, null given, called in /var/www/html/vendor/cobweb/external_import/Classes/ViewHelpers/Be/TableTitleViewHelper.php on line 56

When calling https://example.ddev.site/typo3/module/externalimport/data/DataModule/viewConfiguration?table=tx_news_domain_model_news&index=mykey

Configuration:

$GLOBALS['TCA']['tx_news_domain_model_news'] = [
    'external' => [
        'general' => [
            'vereinsonline' => [
                'connector' => 'json',
                'parameters' => [
                    'uri' => "/var/www/html/var/transient/eventsimport.json",
                    "encoding" => "UTF-8",

                ],
                'data' => 'array',
                'referenceUid' => 'code',
                'priority' => 5000,
                'description' => 'Import Events'
            ],
        ]
    ],
];