Project

General

Profile

Actions

Bug #66535

closed

Property _localizedUid is not set correctly

Added by Uwe Kammerer about 9 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Must have
Assignee:
-
Category:
Extbase
Target version:
-
Start date:
2015-04-22
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
8
PHP Version:
5.6
Tags:
Complexity:
Is Regression:
No
Sprint Focus:

Description

If I set the _localizedUid Property inside my Model to aime to an translated Record, the origin Record gets overwriten. The Problem is caused in the Class TYPO3\CMS\Extbase\Persistence\Generic\Backend in Line 856.

There is the Property set to the current Record UID, so the Object is overwriten.

original Code (Lines 855 - 857):

if ($object->_getProperty('_localizedUid') !== NULL) {
$row['uid'] = $object->_getProperty('_localizedUid');
}

should be changed to:

if ($object->_getProperty('_localizedUid') !== NULL && $dataMap->getTranslationOriginColumnName() !== NULL) {
$row[$dataMap->getTranslationOriginColumnName()] = $object->_getProperty('_localizedUid');
}

after that Change everything works as expected.


Files

sfcategory_1.0.0_201710121908.zip (34.4 KB) sfcategory_1.0.0_201710121908.zip Stefan Froemken, 2017-10-12 19:09
sfcategory_fixed.zip (78.5 KB) sfcategory_fixed.zip Helmut Hummel, 2017-11-04 02:31
Actions

Also available in: Atom PDF