My company has created and compiled BOs as one BO per database table. I'm designing a single form that has to retrieve data from seven different tables, so there are seven BOs on the form. It would be very difficult to have multiple versions of a table-based BO with the same parent but different child BO objects. Because of this, none of these BOs are related to any of the others by the Parent-Child relationship properties.
The form uses a primary BO and passes parameters from the main BO to the other six BOs to retrieve lookup values for fields on the form.
I see that in your tutorials/samples that the BOs are table-based.
As a developer, I have to put a lot of extra code at the form level to update all of the fields on the form that use data coming from the BOs that are not the primary BO.
It seems that it would be easier to base the form on a single database view that already contains the main table values and the lookup values - this way all of the business logic and data can reside in a single instance of a single BO. This would also reduce the amount of form level code by a large amount.
What is the recommended best practice for designing and creating BOs-- view-based or table-based?
Thanks!