SearchTypeParams
The SearchTypeParams which are part of searchConfig.xml contains information about supported search types. The search types provided here are rendered by the REST endpoint search/searchtypes which can be displayed by the UI. Each “SearchTypeParam” has “id” attribute which gives search type name and the “labelKey” provides the label that needs to be displayed in the advanced search form. The translated label is rendered to the client based on the “labelKey”. Typically Search Type parameters are provided to search a particular attribute such as “partname” or “partnumber” and return the search results.
<SearchTypeParams>
<SearchTypeParam id="partname" labelKey="SEARCH_TYPE_PART_NAME"/>
<SearchTypeParam id="partnumber" labelKey="SEARCH_TYPE_PART_NUMBER" />
</SearchTypeParams>
Customization
Adding a new SearchTypeParam provides the UI with the list of supported search types in the advanced search form. For example, to support “ SCMSCode” as a search type parameter add the SearchTypeParameter as shown below and define a translation for the labelKey provided.
<SearchTypeParams>
<SearchTypeParam id="partname" labelKey="SEARCH_TYPE_PART_NAME"/>
<SearchTypeParam id="partnumber" labelKey="SEARCH_TYPE_PART_NUMBER" />
<SearchTypeParam id="SMCSCode" labelKey="SEARCH_TYPE_SMCS_CODE" />
</SearchTypeParams>
Was this helpful?