Skip to content

Commit 20256a9

Browse files
committed
Update reports documentation
1 parent f5bcee6 commit 20256a9

File tree

3 files changed

+18
-5
lines changed

3 files changed

+18
-5
lines changed

src/configuration/ThemesConfiguration.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ The format of the theme definitions is as follows:
179179
| `"searchProviders": ["<Provider>"],` | Optional, list of search providers, see [Search](../topics/Search.md). Defaults to `defaultSearchProviders`. |
180180
| `"minSearchScaleDenom": <number>,` | Optional, minimum scale to enforce when zooming to search results. Takes precedence over value in `config.json`. |
181181
| `"featureReport": {` | Optional, available feature report templates. |
182-
| `⁣  "<LayerId>": "<TemplateID>" ` | WMS sublayer ID and associated template ID to pass to the `featureReportService`.|
182+
| `⁣  "<LayerId>": <TemplateCfg>` | WMS sublayer ID and associated template ID to pass to the `documentService`. See [Reports](../topics/Reports.md). |
183183
| `},` | |
184184
| `"additionalMouseCrs": ["<EPSG code>"],` | Optional, list of additional projections for displaying the mouse position. WGS84 and `mapCrs` are available by default. Additional projections definitions must be added to `config.json`. |
185185
| `"watermark": {` | Optional, configuration of watermark to add to raster export images. |

src/configuration/ViewerConfiguration.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -115,7 +115,7 @@ Some plugins require external services (typically part of the `qwc-services` eco
115115
|`authServiceUrl` | Typically the URL of a QWC authentication service like `qwc-db-auth`. |
116116
|`editServiceUrl` | Typically the URL of the `qwc-data-service`. |
117117
|`elevationServiceUrl` | Typically the URL of the `qwc-elevation-service`. |
118-
|`featureReportService`| Typically the URL of the `qwc-document-service`. |
118+
|`documentService` | Typically the URL of the `qwc-document-service`. |
119119
|`mapInfoService` | Typically the URL of the `qwc-map-info-service`. |
120120
|`permalinkServiceUrl` | Typically the URL of the `qwc-permalink-service`. |
121121
|`searchServiceUrl` | Typically the URL of the `qwc-fulltext-search-service`. |

src/topics/Reports.md

Lines changed: 16 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,13 +37,26 @@ As a second step, associate the report templates to theme layers to expose the r
3737

3838
```json
3939
"featureReport": {
40-
"<layer_name1>": "<template_name1>",
41-
"<layer_name2>": "<template_name2>",
40+
"<layer_name1>": "<template_name>",
41+
"<layer_name2>": [
42+
{
43+
"title": "<title>",
44+
"template": "<template_name>",
45+
"single_report": <false|true>,
46+
"format": "<pdf|docx|...>"
47+
},
48+
...
49+
],
4250
...
4351
}
4452
```
4553

46-
The web client will then display a link to download the report for one or more selected features in the identify results dialog.
54+
The first case example displays the shorthand syntax for assigning one report template to one layer. The second example displays the syntax for assigning one or more templates to one layer, supporting the following extra options:
55+
56+
- `single_report`: If `true`, one report will be compiled and a list of feature IDs will be passed in the report params. If `false`, one report will be compiled for each feature ID, and the result will be a multi-page report (one report per feature). Default is `false`.
57+
- `format`: The report format, one of `pdf`, `html`, `csv`, `docx`, `ods`, `odt`, `pptx`, `rtf`, `xslsx`, `xml`. Default is `pdf`.
58+
59+
The web client will then display a link to download the report(s) for one or more selected features in the identify results dialog.
4760

4861
In addition, the [`Reports` plugin](../references/qwc2_plugins.md#reports) provides a convenient interface to directly select a desired report layer and download the reports for one or more, or all, features of the selected layer.
4962

0 commit comments

Comments
 (0)