Table of Contents
GenIL Component CRM_ES
With the report CRM_ES_STRUC_GEN query and query result structures are generated for each template. These query and query result objects build the GenIL component CRM_ES which is based on the implementation class CL_CRM_GENIL_ES (in package CRM_ES_GENIL). GenIL component and implementation class are owned by the WEBCUIF layer and not by the application. The implementation class contains methods to hold and unhold in order to achieve that all query requests could first be collected and then executed at once. If more than one query is sent to Enterprise Search, they use the so called "bulk" query which sends all queries asynchrony to TREX. Most important method is EXECUTE_QUERY which delegates the query execution to the Enterprise Search (by calling CL_ESH_IF_SEARCH_REQUEST, method SEARCH).
The query result objects are used in the views of UI Component CRM_ES_UI_APPL to display the results from Enterprise Search. In principle, the query and query result objects could also be used by application to build an advanced search view for Enterprise Search query.
Central Search Customizing
The central search hover menu is filled from central search customizing which contains per business role and per UI object type the corresponding query object from the CRM_ES GenIL component.
The menu option Free Text is available for a particular object, if it can be searched with Enterprise Search. The menu option All Objects is available if at least one object can be searched with Enterprise Search.
In suite7 and suite7i10 a search for a numeric id is internally extended by a leading wildcard '*' since leading zeros are stored in the enterprise search index. As a consequence you may find a few more entries than expected in the result list. For details see note 1336702: Searching for IDs using the Enterprise/Simple Search.
UI Component CRM_ES_UI_APPL
The display of the Enterprise Search result list is realized with UI component CRM_ES_UI_APPL which is owned by the application.
It contains one overview page (OVP) and one view per UI object type owned by the application(s), but they inherit from generic WEBCUIF classes (of package CRM_ES_UI):
- OVP: controller inherits from generic class CL_CRM_ES_U_SEARCHRESULT0_IMPL With the help of the component controller the search information sent from the hover menu are retrieved in the inbound plug IP_ES_SEARCH and all search results are requested once. In DETACH_STATIC_OVW_VIEWS the hit counts are retrieved to update the title of each assignment block in the OVP with the hit count and the views are detached from the OVP for which no query was sent from the hover menu. REATTACH_STATIC_OVW_VIEWS is used if all views needs to be reattached again after switching from object specific search ("Free Text") to "All Objects" search.
- View: controller inherits from generic controller class CL_CRM_ES_VIEW_CONTROLLER and context node from generic context node class CL_CRM_ES_CONTEXT_NODE The generic controller ensures in DO_HANDLE_EVENT that events such as sort, filter, paging, personalization popup close are not using the standard framework logic but are delegating to call the search again. In the event EH_ONTOROOT the root object of the template is created and navigation is triggered via the corresponding UI object type and action B (Display). Normally the root object is the right object, if not application need to redefine this method. The generic context node class ensures in GET_TABLE_SIZE that the pager is rendered correctly as the retrieved data form Enterprise Search is only the visible table size, but in GET_TABLE_SIZE the total hit count is returned. Also GET_LINE_INDEX calculate the right index of collection item.