[BUGFIX] Allow subclasses of \DateTime as entity properties 90/42590/2
authorStephan Schuler <stephan.schuler@netlogix.de>
Wed, 13 May 2015 13:05:35 +0000 (15:05 +0200)
committerAndreas Wolf <andreas.wolf@typo3.org>
Thu, 13 Aug 2015 19:34:49 +0000 (21:34 +0200)
commit39b4993a8d87802149a3960fc4d66967cc0917fb
treed133511db7dff789e4795b0de5e1c10acddd9c01
parent1c9922353f2ed83bff81af6bb10756422a2da252
[BUGFIX] Allow subclasses of \DateTime as entity properties

When a class "\MyCustomDateTime extends \DateTime", the data mapper
creates "\DateTime" objects instead when mapping database results.
This patch uses the class annotation to resolve the class to create.

Resolves: #66939
Releases: master, 6.2
Change-Id: I45062d4d1a44333016258289ea9e2026d9923f70
Reviewed-on: http://review.typo3.org/42590
Reviewed-by: Andreas Wolf <andreas.wolf@typo3.org>
Tested-by: Andreas Wolf <andreas.wolf@typo3.org>
typo3/sysext/extbase/Classes/Persistence/Generic/Mapper/DataMapper.php [changed mode: 0644->0755]
typo3/sysext/extbase/Tests/Unit/Persistence/Fixture/Model/CustomDateTime.php [new file with mode: 0644]
typo3/sysext/extbase/Tests/Unit/Persistence/Generic/Mapper/DataMapperTest.php