Details
-
Improvement
-
Resolution: Fixed
-
Major
-
None
-
None
Description
DBListClass uses a query to populate the displayed selectbox with values. It would be useful to be able populate not only the values, but also the displayed text for each value.
For example, i have a colection of objects in the database, each object having an id and a displayed name. Populating the DBListClass with ids enforces the user to lookup/remember ids, and this should be avoided. Populating it with names negates the role of the id.
There are 2 variants for this:
- add a new field in the Meta class, has_labels
- detect if the resultset is composed of single values or pairs
Please advise.