[TYPO3-mvc] PropertyMapper in scheduler command
Heiko Kromm | Paints
h.kromm at paints.de
Thu Jul 5 15:19:13 CEST 2012
Hi list,
I have a commandController, which is called by the scheduler.
In this Controller I want to map data to my domain model. My domain model has a 1:n relation.
I map the data like this:
$newObject = $this->propertyMapper->convert(
array(
'pid' => 3,
'myName' => 'Test',
'relationObject' =>array(
'relationObjectName' => 'Test2',
'pid' => 3
)
), 'Tx_MyExtension_Domain_Model_Testmodel'
);
Without the relationObject it works fine. But if I want to have the relationObject created, I get this error:
Exception while property mapping at property path " relationObject ":Creation of objects not allowed. To enable this, you need to set the PropertyMappingConfiguration Value "CONFIGURATION_CREATION_ALLOWED" to TRUE
Any hints on how I can set the value to true?
Thanks
Heiko
More information about the TYPO3-project-typo3v4mvc
mailing list