index



modules



license
coding style
to do



Tables with small, medium, large expected amount of records

Usage:

Example:

<table name="Example" expected-amount="small">
</table>

The default expected amount is "large".
The function OMRootTable.isExpectedAmountXXX() and OMTable.isExpectedAmountXXX() are used in the templates to get this info. (where XXX is one of: "Small", "Medium", "Large").

Differences:

1) Tables with small/medium amount of records have an extra select added automatically. The name is "UnidAll". This select has no selections, so it gets all the records in that table.

2) The look of link fields in GUI depends on the expected amount of records of the link table.

For links to tables with small amount of records, there are:
-a widget with selection-list (a html select) where all existing records in the table are shown (each option is a string with the values of the display fields for the record.)
-a href, its text showing the current value of the link (in the form of a string with the display fields). This would open a popup, showing the full record currently selected in view mode. From there, you can choose "Edit" to edit the current link.

Links to tables with large and medium amount of records look the same way:
-a href with text "Select". This opens a popup with a list of all the finders in that page + a link to add a new record. Choosing one of the results of that finders, or creating a new record, the popup closes and the value of the link is updated in the opener page.
-a href, its text showing the current value of the link (in the form of a string with the display fields). This would open a popup, showing the full record currently selected in view mode. From there, you can choose "Edit" to edit the current link.
(This part, the display of the link fiels, that you can click for View/Edit, is the same as for links to tables with small amount of records).

3) There are also differences in GUI when you edit parameters for actions/reports/finders or just fields, and these have suggests with a table and a field:

-If the suggested table has small amount of records, there is a html select near the parameter widget. The select contains the values of the sugested field, for all existing records in that table. If you click one, the suggested field's value will be set in the parameter widget.
-If the suggested table has medium or large amount of records, there is a button with text "..." near the parameter widget. This opens a popup with a list of all the finders in that page + a link to add a new record. Choosing one of the results of that finders, or creating a new record, the popup closes and the value of the suggested field for the chosen/created record is updated in the opener page.
(The look of the suggests with table & field is very much like setting links in GUI, but internaly, instead of choosing/setting uoid's, it sets the value of a field).

$Id: ExpectedAmount.wiki 1132 2005-02-16 07:09:34Z cabnetrom $