The definitions in this article apply to both controls. When behavior/display differs it will be marked.
The LookupInput(2) control is one of the most complex controls in DomUI. It allows selection of some data record either by doing a "quicksearch" or by opening a full lookup form to find the record. For example, when adding an "order" this control would be used to find the customer that the order is added for by allowing the user to search the "customers" table and to select one of those.
This control is highly configurable and has several display states. Some examples:
All of these are LookupInput controls in different states.
The control has three main modes of operation:
Whether a control is in "normal" or "quicksearch" mode depends on the configuration of the control; to be able to do quicksearch the control must "know" which fields of the entity must be used to search on. If no such fields are defined/known the control works in "normal" mode.
In normal mode the control looks as follows:
The "no selection" text is fixed and the box is not an input box. FIXME: this should be visible in another way, because this looks like an input.
To select a value the user clicks the lookup button which opens the lookup dialog. If a value is selected there the control changes to "value" state.
In this mode the "clear" button is disabled as the value's already empty.
Requirements: