Configuring the Quick Search
Learn to configure quick search.
The Quick Search configuration is specified using the JSON syntax. For further details, see http://www.json.org.
The default Quick Search is defined in the QuickSearch.json.js file located in the ..web\data\settings directory.
To customize the Quick Search, create your own configuration file and apply it via the Web
Configuration parameter QuickSearch.Definition
. For further details,
see QuickSearch.Definition.
The QuickSearch.json.js file contains search providers defining the following:
- the Quick Search drop-down list (labels, defaults)
- the actual search definitions via AQL statements (see AQL Syntax) and/or predefined
queries
{ searchProvider: [ new u8.Crm.SearchProvider({ isActive: true, label: u8.services.schema.idToLabelPlural("FI"), useFirstSearchTermForAllParameters: true, query: new u8.Crm.QueryCommand({ statement: "select (Company, City, Country) from (FI as root) where (Company = '$parValue' or Synonym = '$parValue' or Country = '$parValue')", catalogValueEncoding: "Text"}) }), new u8.Crm.SearchProvider({ isActive: true, label: u8.services.schema.idToLabelPlural("MA"), maxRows: 10, query: new u8.Crm.QueryCommand({ name: "QuickSearchPredefinedQueryName"}) }) ] }
Each search provider specifies an entry of the Quick Search drop-down list (i.e. an info area to be searched). The Select all option is hard-coded and cannot be removed.
In the BTB vertical the standard Quick Search definition contains FI, KP, MA and Y1. Y1 is not searched by default. The standard definitions for the OTC and FS verticals contain FI,KP and MA.
The following parameters are used:
Name |
Type |
Description |
---|---|---|
|
boolean |
Determines if the search provider is used by default (i.e. the entry in the Quick Search drop-down list is checked). Default: |
|
string |
Sets the title of the quick search result for the provider. |
|
int |
Optional: The maximum number of rows to be displayed as a search result. Default: If more than
Clicking on the link displays all search results in a
|
|
boolean |
If set to Default: |
|
u8.Crm.QueryCommand |
The query that is executed (define the query as
|
|
string |
The name of a predefined query. |
|
string |
The query statement specified using AQL, see AQL Syntax. (The
Note:
*$parValue is only supported by text fields and only in AQL
queries (i.e. not in predefined queries). |
The Quick Search definition only supports text, number and variable catalog fields. These field types may be combined in one definition (in both the search and output fields. If an unsupported field type is used, a warning is written to the client log.
QuickSearch.Definition
Web Configuration parameter or remove all searchProvider
definitions from the *.js file.