Blank Page type with Search Component filtering Content Copied taxonomy members in an Entity

Pre-requisite: Sitecore Content Hub Sandbox 4.1.1

In this blog article, I cover how to add a search component to a blank page type and filter results from taxonomy member present in an entity.

A summary of this blog:

a. Security toggle is in General Information tab for string or option list member while it is present in Advanced tab for taxonomy member

b. To include search results of a taxonomy member while searching the parent entity, switch on "Content copied" toggle in the taxonomy member

c. Add search component to a blank page type

d. In the search component, add a simple filter that points to an entity definition

e. Toggle full-text in functionality tab of the search component

f. In order to open a detail page on click of entity thumbnail, add operation in "main click area" and link to a detail page

g. "Add Operation" allows for options like Generate PDF, download, preview among others

Here are the detailed steps:

1. Add a search page through Settings -> Pages (page type - "Blank Page"):


2. Now, add a search component:


3. Toggle visibility:


4. Edit component: 


5. Let's add a filter and point this to the testschema entity:


6. Schema saved:


7. Next, in the output tab, toggle show definition on thumbnail:


8. Click View page after save and close:


9. Can get a list of entities but not searchable or clickable:


10. Edit the search component and toggle full-text search functionality:



11. Save and close then refresh the search page to find the search box with all entities listed:


12. Based on the entity list fields, let us search for a string present in one of the string fields in an entity and see if it is filtered, seems good:



13. Next, let's search a field in one of the taxonomy members, no results:


14. Let's switch over to the taxonomy member definition within the entity definition and toggle "Content Copied" option present in the Advanced tab:


Note that in case of the string member in an entity definition, the secured toggle is present in General Information tab:


This is a common question in the content hub certification exam as to where controls will be present in case of different members. Note that option list and string member will only have General Information tab while taxonomy and entity associated members will have advanced tab.

Also, note that in case of string members, "Include in content" does the job of "content copied" present in taxonomy and entity associated member definition.

Since the Content Copied toggle is on and saved, let us try searching a part of the taxonomy tag and see what happens. And, always remember to apply changes to the entity definition.

15. Search provides the following results from the taxonomy member:


16. On refining the filter, the search results seem to change:


17. Now, in order to open the entity details page on click of the thumbnail, switch back to the search component and "add operation" in "main click area" and select view detail page:


18. Select View Detail page, click to add a link and add reference to the test page added in an earlier blog:


19. This is how the setting looks:


20. So, finally the main click area has the needed setting to open the detail page on clicking the thumbnail:


21. Save and close the component. Then, refresh the search page and the thumbnail must be clickable and should open the detail page for the entity:



Comments

Popular Posts