|
5.3 How to Model a Basic Page An unstyled, basic page allows information to be displayed and entered primarily for a single dataview record. Most update pages are basic pages. If the dataview is backed by an initial entity, you can access records held in the database table fronted by the entity through functionality built into the transform. Connections to related dataviews (also backed by an entity) will normally allow you to connect to rows based on the relation, but not edit information on the individual fields directly. An exception is a contained relationship. The displayStyle on a dataview end decides how the connections are handled, and which displayStyles are supported depend on the multiplicity. If no displayStyle is defined, the relationship will not be shown. to-one relationships:
to-many relationships:
It's worth noting that there are no to-many relationships designed for use with a large number of fields. For this a subsidiary styled page, (list or listadd) should be used. Most of this functionality is available even if the dataview is not backed by an initial entity. Anything which involves links to other pages with database functionality such as lookup, will not work, but the basic display and edit functionality will. The main differences being that the data will have to be prepared for the page by explicitly written code, and any changes will have to be persisted in the database also by explicitly written code. You may want to model database access this way, because the information to be persisted is in a very different format to that collected on the page. You have to keep in mind the different needs of the users ease of use and the database you are storing information in. If you are using a legacy system, the latter may be beyond your control. If so it is necessary to provide the hooks for the application programmer on the events. Links:
Copyright © 2001-2006 New Technology / enterprise Ltd. | |||||||||||||||||||||||||||||||||||||||