Skip to content

Commit 1ba10ad

Browse files
author
Luis Cabrera
committed
Readme explains how geolocation and translation can be shown in the document details.
1 parent e126455 commit 1ba10ad

File tree

3 files changed

+11
-0
lines changed

3 files changed

+11
-0
lines changed

02 - Web UI Template/README.md

+11
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,9 @@ Update the following fields in the *appsettings.json* file to connect the web ap
2929
"StorageContainerAddress": "https://{storage-account-name}.blob.core.windows.net/{container-name}",
3030
"KeyField": "metadata_storage_path",
3131
"IsPathBase64Encoded": true,
32+
"AzureMapsSubscriptionKey": "",
3233
"GraphFacet": "keyPhrases"
34+
3335
```
3436

3537
###
@@ -39,6 +41,10 @@ Update the following fields in the *appsettings.json* file to connect the web ap
3941
3. Key Field should be set to the field specified as a key document Id in the index.
4042
4. Sometimes metadata_storage_path is the key, and it gets base64 encoded. In that case set IsPathBase64Encoded to false.
4143
5. The GraphFacet is used for generating the relationship graph.
44+
6. You can optially provide an Azure Maps account if you would like to display a geographic point in a map for a given document.
45+
The template expects a field called *geolocation*. If your field has a different name, you can modify details.js to use a different field.
46+
47+
![geolocation](../images/geolocation.png)
4248

4349

4450
## 2. Update SearchModel.cs
@@ -57,6 +63,11 @@ If you would like to further customize the UI, you can update the following fiel
5763
## 3. Add additional customization
5864
This template serves as a great baseline for a Cognitive Search solution, however, you may want to make additional updates depending on your use case.
5965

66+
We have a special behavior if you have a field called *translated_text*. The UI will automatically show the original text and the translated text in the UI. This can be handy. If you would like to change this behavior (disable it, or change the name of the field), you can do that at details.js (GetTranscriptHTML method).
67+
68+
![geolocation](../images/translated.png)
69+
70+
6071
### *Notes*
6172
Much of the UI is rendered dynamically by javascript. Some important files to know when making changes to the UI are:
6273

images/geolocation.png

117 KB
Loading

images/translated.png

101 KB
Loading

0 commit comments

Comments
 (0)