We would like to have a single visualforce page displays both the parent detail and child detail together. The idea here is to prevent the user from having to traverse from the child to the parent to see the record details.
Know we could have a single detail component which would display the child record using the standard controller. ( we could write custom apex controller to retrieve the parent record fields and display this on the visualforce page ) but it is possible to have two detail components on a single page for both the parent and child. In our example the parent record is very complex and subject to change so we do not wish to attempt to custom code this layout via visualforce and would like to leverage the detail component.
the code would looks something like this:
<apex:page standardController="AccountChild">
<apex:detail subject="{!accountChild.Id}" relatedList="false" />
<apex:detail subject="{!account.Id}" relatedList="false" />
</apex:page>
But I do not think this is possible as a detail component must be attached to a singular standardController object..
Id
, not the record's Name. It's a little surprising you believe the<apex:detail>
is bound in any way to thestandardController
considering you know about thesubject
attribute, but maybe this misunderstanding has something to do with it.