[FLOW3-general] child objects in JsonView
Thomas Mammitzsch
thomas at visualworx.de
Wed Dec 12 23:44:34 CET 2012
hi list,
i think its a missing feature, that
TYPO3_Flow_Mvc_View_JsonView->transformObject() doesn't transform child
objects of the parent object. A workaround is the following in controller:
$json = json_encode($parentobjects);
header("Content-Type: application/json");
echo $json;
die();
Thats an ugly bastard it think, but it works. I'm using PHP 5.4 and
implement JsonSerializable in my model classes to get this to work.
regards, Thomas
More information about the FLOW3-general
mailing list