ezsystems/ezpublish-legacy — pull request #586 by patrickallaert (2013-04-02 11:42:08+00:00)
Title: Fixed EZP-18195: $result.object is not correctly created

EZP-18195 duplicates in fact EZP-6838 which has been fixed in an
inappropriate way in cb8ef8f8b66dafbc302fa9c10dae5293b2d95634.

This fix reverts the previous work around. Only relevant columns are
returned and `object remote_id` is returned as `object_remote_id`.

The `remote_id` key still contains the one of the node to ensure BC.

The `eZContentObject` constructor has been revised to additionally
handle information that are frequently given to him and not exploited
especially when created from `eZContentObjectTreeNode`.

This fix improves performance when `remote_id` or content class
information of an `eZContentObject` contained in an
`eZContentObjectTreeNode` are accessed by avoiding additional SQL
queries.

It should also improves the usage of the DBMS query cache mechanism
since fewer columns are retrieved by the modified SQL queries.