Bug #80239
closedcreate new IRRE-Element cause exception in multi-language-evoirement
100%
Description
I used the TYPO3 8.6.1 - build via composer 6.3.2017
XAMPP PHP 7.0.5
Scenario:
- My Extension define some content-elements
- I have a content-element with an own model
- The CE has an 1:1 IRRE relation to an other model.
- If I try to create the IRRE-Relation in the backend in the default language, i se the estimated form
- If I try to save the created IRRE-Element, I got the exception below
- If I try to create the Element with my own frontend-editing (extbase; create Action with dummy-element-generation), the IRRE will be shown after that in the backend
- After I created the IRRE for the default language with my frontend-mechanism, I can use the feature of synchronisation of records for the other languages and it seems to work fine
Exception:
Uncaught TYPO3 Exception Argument 3 passed to TYPO3\CMS\Core\DataHandling\Localization\DataMapProcessor::synchronizeTranslationItem() must be of the type integer, null given, called in C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\sysext\core\Classes\DataHandling\Localization\DataMapProcessor.php on line 195 TypeError thrown in file C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\sysext\core\Classes\DataHandling\Localization\DataMapProcessor.php in line 233. 14 TYPO3\CMS\Core\DataHandling\Localization\DataMapProcessor::synchronizeTranslationItem(TYPO3\CMS\Core\DataHandling\Localization\DataMapItem, array, NULL) C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\sysext\core\Classes\DataHandling\Localization\DataMapProcessor.php: 00193: $fromId = $item->getIdForScope($scope); 00194: $fieldNames = $this->getFieldNamesForItemScope($item, $scope, !$item->isNew()); 00195: $this->synchronizeTranslationItem($item, $fieldNames, $fromId); 00196: } 00197: $this->populateTranslationItem($item); 13 TYPO3\CMS\Core\DataHandling\Localization\DataMapProcessor::enrich() C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\sysext\core\Classes\DataHandling\Localization\DataMapProcessor.php: 00100: if (!empty($this->items)) { 00101: $this->sanitize(); 00102: $this->enrich(); 00103: } 00104: return $this->dataMap; 12 TYPO3\CMS\Core\DataHandling\Localization\DataMapProcessor::process() C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\sysext\core\Classes\DataHandling\DataHandler.php: 00982: } 00983: // Pre-process data-map and synchronize localization states 00984: $this->datamap = DataMapProcessor::instance($this->datamap, $this->BE_USER)->process(); 00985: // Organize tables so that the pages-table is always processed first. This is required if you want to make sure that content pointing to a new page will be created. 00986: $orderOfTables = []; 11 TYPO3\CMS\Core\DataHandling\DataHandler::process_datamap() C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\sysext\backend\Classes\Controller\EditDocumentController.php: 00573: // Perform the saving operation with DataHandler: 00574: $tce->process_uploads($_FILES); 00575: $tce->process_datamap(); 00576: $tce->process_cmdmap(); 00577: // If pages are being edited, we set an instruction about updating the page tree after this operation. 10 TYPO3\CMS\Backend\Controller\EditDocumentController::processData() C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\sysext\backend\Classes\Controller\EditDocumentController.php: 01991: // Checks, if a save button has been clicked (or the doSave variable is sent) 01992: if ($this->doProcessData()) { 01993: $this->processData(); 01994: } 01995: 9 TYPO3\CMS\Backend\Controller\EditDocumentController::mainAction(TYPO3\CMS\Core\Http\ServerRequest, TYPO3\CMS\Core\Http\Response) 8 call_user_func_array(array, array) C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\sysext\backend\Classes\Http\RouteDispatcher.php: 00052: $targetIdentifier = $route->getOption('target'); 00053: $target = $this->getCallableFromTarget($targetIdentifier); 00054: return call_user_func_array($target, [$request, $response]); 00055: } 00056: 7 TYPO3\CMS\Backend\Http\RouteDispatcher::dispatch(TYPO3\CMS\Core\Http\ServerRequest, TYPO3\CMS\Core\Http\Response) C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\sysext\backend\Classes\Http\RequestHandler.php: 00138: /** @var RouteDispatcher $dispatcher */ 00139: $dispatcher = GeneralUtility::makeInstance(RouteDispatcher::class); 00140: return $dispatcher->dispatch($request, $response); 00141: } 00142: } 6 TYPO3\CMS\Backend\Http\RequestHandler::dispatch(TYPO3\CMS\Core\Http\ServerRequest) C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\sysext\backend\Classes\Http\RequestHandler.php: 00070: // Check if the router has the available route and dispatch. 00071: try { 00072: return $this->dispatch($request); 00073: 00074: // When token was invalid redirect to login 5 TYPO3\CMS\Backend\Http\RequestHandler::handleRequest(TYPO3\CMS\Core\Http\ServerRequest) C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\sysext\core\Classes\Core\Bootstrap.php: 00308: 00309: // Execute the command which returns a Response object or NULL 00310: $this->response = $requestHandler->handleRequest($request); 00311: return $this; 00312: } 4 TYPO3\CMS\Core\Core\Bootstrap::handleRequest(TYPO3\CMS\Core\Http\ServerRequest) C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\sysext\backend\Classes\Http\Application.php: 00091: } 00092: 00093: $this->bootstrap->handleRequest($this->request); 00094: 00095: if ($execute !== null) { 3 TYPO3\CMS\Backend\Http\Application::run() C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\sysext\backend\Resources\Private\Php\backend.php: 00022: $classLoader = require __DIR__ . '/../../../../../../vendor/autoload.php'; 00023: 00024: (new \TYPO3\CMS\Backend\Http\Application($classLoader))->run(); 00025: }); 2 {closure}() C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\sysext\backend\Resources\Private\Php\backend.php: 00023: 00024: (new \TYPO3\CMS\Backend\Http\Application($classLoader))->run(); 00025: }); 1 require("C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo…3\sysext\backend\Resources\Private\Php\backend.php") C:\xampp\htdocs\comic\Source\vendor\typo3\cms\typo3\index.php: 00001: <?php 00002: 00003: require __DIR__ . '/sysext/backend/Resources/Private/Php/backend.php';