Types of Type Ahead ConfigurationsType ahead can be achieved using any of these methods:
If a field is defined with both a custom JPO and advanced search for Type Ahead, then the custom JPO is used. Advanced Search Used for Type AheadDevelopers can use the advanced search function, emxFullSearch.jsp, to quickly configure a form field or table column for type ahead. This method of implementing relies on the indexed searching provided by the Advanced Search feature. Only those fields defined in config.xml for indexing can be used for automatic type ahead. When the user starts typing in the field, they get the same initial suggestion list that they would get if they clicked the To implement type ahead using advanced search, you need to provide values as follows:
If a field has a value defined for Type Ahead Mapping and the TypeAhead Program and Type Ahead Function settings, then the JPO method overrides the mapping to the config.xml file. If you need to restrict the suggestion list based on the current context, such as restricting task owners to those users who have access to the project the task belongs to, you can pass macros. For example: emxFullSearch.jsp?field=TYPES=Person:PROJECT_ID=${<setting_name>}&table... where setting_name is the name of the setting on the form or column. This setting value is a select expression to retrieve the runtime value for the query based on the object Id. See Appendix: Selectables and Appendix: Macros for more details. If the user could be expected to enter a value that may be in more than one field, you can provide an OR list of fields. For example, when selecting a Person, the user could start typing that Persons' first name, their last name, or perhaps their user name. To configure the field for this type of entry, you can use this format (OR is indicated by the double-pipe symbols): emxFullSearch.jsp?field=TYPES=Person:LASTNAME=*<enteredtext>*||FIRSTNAME=*<enteredtext>*||USERNAME=*<enteredtext>* where <enteredtext> is the text the user typed into the field. These properties in emxSystem.properties file used by the Type Ahead using JPO feature are also used by the automatic Type Ahead feature:
If you change the values for these properties, both the advanced search and custom JPO type ahead features are affected. Pre-Defined Type Ahead ChoosersThe most commonly searched-for values when filling in dialogs are Person, Organization, and Type. Business Process Services allows a developer to configure type ahead by setting the value for the Range Href setting for the field to one of these values:
See Configurable Type Chooser for details on configuring the field to use this chooser. When the user starts typing in the field, they get the same initial suggestion list that they would get if they clicked the The PERSON_CHOOSER href maps to this: ${COMMON_DIR}/emxFullSearch.jsp?field=TYPES=type_Person:STATE=Active& table=AEFPersonChooserDetails&selecton=single& submitURL=${COMMON_DIR}/emxPersonChooserSelectProcess.jsp In addition, the Type Ahead Mapping setting on the field should be set to FIRST_NAME,LAST_NAME,NAME. The ORGANIZATION_CHOOSER href maps to this: ${COMMON_DIR}/emxFullSearch.jsp? field=TYPES=type_Organization:STATE=Active&table=AEFOrganizationChooserDetails& selection=single&submitURL=${COMMON_DIR}/emxOrganizationChooserSelectProcess.jsp In addition, you must set the value for the Type Ahead Mapping setting on the field to Name. If the application requires restricting the value for the field more than that defined by the above hrefs, you can also define a value for the Additional Query setting on the field or column using this syntax: "Additional Query" = <FieldName1>=<select expression1>:<FieldName1>=<select expression2>: The Field Names used in the expression must be the names of fields configured for indexing in config.xml. See Appendix: Selectables for details on select expressions for the current object. |