CodeIgniter Forums
Datamapper object to_array() - including related objects - Printable Version

+- CodeIgniter Forums (https://forum.codeigniter.com)
+-- Forum: Archived Discussions (https://forum.codeigniter.com/forum-20.html)
+--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forum-22.html)
+--- Thread: Datamapper object to_array() - including related objects (/thread-59661.html)



Datamapper object to_array() - including related objects - El Forum - 11-01-2013

[eluser]Unknown[/eluser]
Hello,

When you include a related object as a field in the parameters the related object is returned as an array of its id's. This is the intended behaviour of datamapper, however is it possible to instead output the full object?

Thanks,

Jonathan