Friday 07 September 2007 10:58:34 am
That’s quite easy to fix, write a small template operator that takes care of the fetching by fetching all objects at once. In the api you can fetch several nodes at once using:
eZContentObjectTreeNode:fetch
Or several objects at once using:
eZContentObject::fetchIDArray
The first one will skip trashed objects, and the last one will have main_node_id set to NULL if I remember correctly. If you for some reason have waste amounts of relations, you should also let the operator handle paging.
{def $objects = multi_object_fetch( $node.data_map.rl_attribute.content.relation_list[, $offset = 0[, $limit = 10 ] ] )}
eZ Online Editor 5: http://projects.ez.no/ezoe || eZJSCore (Ajax): http://projects.ez.no/ezjscore || eZ Publish EE http://ez.no/eZPublish/eZ-Publish-Enterprise-Subscription
@: http://twitter.com/andrerom
|