Skip to content

Commit aa12f45

Browse files
authored
Merge pull request #2900 from MicrosoftDocs/portals-1842600
Portals additional entity search - 1842600
2 parents 839ce78 + ca82b40 commit aa12f45

File tree

1 file changed

+38
-27
lines changed

1 file changed

+38
-27
lines changed

powerapps-docs/maker/portals/configure/search-additional-entities.md

Lines changed: 38 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ author: sandhangitmsft
55
ms.service: powerapps
66
ms.topic: conceptual
77
ms.custom:
8-
ms.date: 04/28/2020
8+
ms.date: 09/22/2020
99
ms.author: sandhan
1010
ms.reviewer: tapanm
1111
---
@@ -14,18 +14,28 @@ ms.reviewer: tapanm
1414

1515
## Overview
1616

17-
You can enable additional entities for search functionality. Configuring search for additional entities requires additional actions, which are described in this article.
17+
You can enable additional entities for search functionality. Configuring search for additional entities requires additional actions, which are described in this article. These explicit configuration steps ensure that no records will accidentally be made available using global search.
1818

19-
Following considerations apply when configuring additional entities for global search:
19+
## Steps to configure search for additional entities
2020

21-
- Ensure that the [site setting](#site-setting-for-additional-entities) for search for additional entities is enabled.
22-
- Create a view named **Portal Search** for any additional entity you want to enable search for. More information: [searchable fields in global search](search.md#fields-searchable-in-global-search)
23-
- Ensure an **Entity Permission** is created that provides Read privilege, and appropriate scope for the records to show in search results.
24-
- Associate the entity permission with required **Web Roles**.
25-
- Entity permissions must be associated with the **Anonymous Web Role** if you want to allow anonymous search for an entity.
26-
- Configure a [search results page](#results-page-for-additional-entities) to display search results.
21+
To configure search for additional entities:
2722

28-
The explicit configuration explained above ensures that no records will accidentally be made available via global search.
23+
1. [Enable additional entities search](#step-1-add-or-update-search-site-settings) for the first time by adding a new setting [Search/EnableAdditionalEntities](#site-setting-for-additional-entities) and set it to *true*. This is a one-time step that enables search for all additional out-of-the-box and custom entities.
24+
25+
1. [Create Portal Search view](#step-2-create-or-verify-the-portal-search-view) for each additional entity with the required filters and columns that needs to be searchable.
26+
27+
1. [Configure entity permissions](#step-3-create-entity-permissions) for each additional entity with a Web Role to have at least read privilege. Skip this step if you already have the read permissions configured for each entity.
28+
29+
1. [Create a record details page](#step-4-add-record-details-webpage) for each entity to show the [details of the selected record](#site-marker-for-record-details-page) from the search results page. Skip this step if you already have created separate results record details page for each entity.
30+
31+
1. [Create a site marker](#step-5-add-a-site-marker-for-record-details-webpage) named `<entitylogicalname>_SearchResultPage` for each entity with the associated [record details page](#site-marker-for-record-details-page).
32+
33+
1. [Rebuild the search index](#step-6-rebuild-the-search-index).
34+
35+
1. [Verify the search results](#step-7-verify-that-global-search-works-with-the-custom-entity).
36+
37+
> [!WARNING]
38+
> If you don't create a record details page, or if you don't bind the record details page with site marker for search, you won't be able to select the additional entity records from search results page to view the record details.
2939
3040
### Site setting for additional entities
3141

@@ -34,24 +44,22 @@ The site setting **Search/EnableAdditionalEntities** is required when configurin
3444
> [!IMPORTANT]
3545
> **Search/EnableAdditionalEntities** is explicitly for enabling search for additional entities. The main search site setting **Search/Enabled** must be set to **true** when using search functionality.
3646
37-
You can also configure other related site settings similar to the search configuration for default entities. For example, you can use the **Search/Filters** setting to configure additional entities and add a drop-down filter option to the global search. More information: [Site setting](search.md#related-site-settings)
38-
39-
### Results page for additional entities
40-
41-
The search result page is configured via a **Site Marker** named ```<entitylogicalname>_SearchResultPage```.
47+
You can also configure other related site settings similar to the search configuration for default entities. For example, you can use the **Search/Filters** setting to configure additional entities and add a drop-down filter option to the global search. More information: [Site setting](search.md#related-site-settings).
4248

43-
For example, if your entity logical name is *nwind_products*, the site marker will be ```nwind_products_SearchResultPage```. The value of the site marker is the page that you want to open when that search result is selected. By default, a record ID is passed in the *id* querystring parameter to the search results page.
49+
### Site marker for record details page
4450

45-
Ensure that your search results page has an entity form, or has logic written to show the search result details.
51+
The record details page is configured using a **Site Marker** named `<entitylogicalname>_SearchResultPage`.
4652

47-
## Walkthrough - configure search for additional entities with sample database
53+
For example, if your entity logical name is *nwind_products*, the site marker will be `nwind_products_SearchResultPage`. The value of the site marker is the record details page that you want to open when that search result is selected. By default, a record ID is passed in the *id* querystring parameter to the record details page. For more information about adding forms on a page, go to [Compose a page](../compose-page.md#add-form).
4854

49-
The following walkthrough explains how to enable search for the **Order Products** entity in the sample database **Northwind**, available with Common Data Service.
55+
> [!IMPORTANT]
56+
> Ensure that your record details page has an entity form, or has logic written to show the search result details. For example, [Step 4 - Add record details page](#step-4-add-record-details-webpage) in the following walkthrough.
5057
51-
For more information about sample databases, see [Install Northwind Traders database and apps](../../canvas-apps/northwind-install.md).
58+
The following walkthrough explains each step in detail with a sample database and solution to configure search for additional entities.
5259

53-
> [!TIP]
54-
> You can follow the walkthrough with an entity of your choice by replacing the *nwind_products* entity name with your entity's logical name.
60+
> [!NOTE]
61+
> - This walkthrough explains how to enable search for the **Order Products** entity in the sample database **Northwind**, available with Common Data Service. For more information about sample databases, see [Install Northwind Traders database and apps](../../canvas-apps/northwind-install.md).
62+
> - You can follow the walkthrough with an entity of your choice by replacing the *nwind_products* entity name with your entity's logical name.
5563
5664
## Step 1: Add or update search site settings
5765

@@ -93,7 +101,7 @@ For more information about sample databases, see [Install Northwind Traders data
93101

94102
1. Select the **Order Product** entity, and then select **Views**.
95103

96-
![Views](media/search-additional-entities/views.png "Views")
104+
![Order Product - Views](media/search-additional-entities/views.png "Order Product - Views")
97105

98106
1. Ensure that you see **Portal Search** in the views list.
99107

@@ -143,7 +151,7 @@ For more information about sample databases, see [Install Northwind Traders data
143151

144152
![Add authenticated users](media/search-additional-entities/add-authenticated-users.png "Add authenticated users")
145153

146-
## Step 4: Add a webpage
154+
## Step 4: Add record details webpage
147155

148156
1. Go to [Power Apps](https://make.powerapps.com), and select **Apps** in the left navigation pane.
149157

@@ -153,7 +161,10 @@ For more information about sample databases, see [Install Northwind Traders data
153161

154162
![New page](media/search-additional-entities/new-page.png "New page")
155163

156-
1. Enter the webpage name as **Order Products**. This page will be configured as the search results page.
164+
1. Enter the webpage name as **Order Products**.
165+
166+
> [!NOTE]
167+
> This page will be shown when users select a record from the search results page to view the details of the selected record.
157168
158169
1. Select **Components** in the left navigation pane, and then add a **Form** component to this webpage.
159170

@@ -163,7 +174,7 @@ For more information about sample databases, see [Install Northwind Traders data
163174

164175
![Set the mode](media/search-additional-entities/mode.png "Set the mode")
165176

166-
## Step 5: Add a site marker for the search results details page
177+
## Step 5: Add a site marker for record details webpage
167178

168179
1. Sign in to [Power Apps](https://make.powerapps.com).
169180

@@ -196,7 +207,7 @@ For more information about sample databases, see [Install Northwind Traders data
196207

197208
1. Go to the search toolbar or the search page, and search for a known record.
198209

199-
For example, use the search keyword **Northwind Clam Chowder** to display results associated with the **nwind_products** entity.
210+
For example, use the search keyword **Northwind Clam Chowder** to get the results associated with the **nwind_products** entity.
200211

201212
![Search results](media/search-additional-entities/search-results.png "Search results")
202213

0 commit comments

Comments
 (0)