Viewing the results of a search operation
Released: HTML page
When defining search operations, you can specify that only the result list is to be displayed. Your users can then view the results of a search directly and no longer have to specify the individual properties. The result list makes it easy for your users to continue their work. However, the users can no longer change the search criteria that led to the result.
To display only the results of a search operation, you must perform the following steps:
Determining the URL for a repository
Determine the link relation for retrieving the results of a search operation
Specify response control parameters
Open the URL for the results
Once you have created a mapping for a source, you can also display the results of a search operation in other ways. For additional information see chapter Retrieving and viewing the results of a search operation.
Determining the URL for a repository
In the chapter Determining a repository, you can learn how to determine the URL for a repository.
Determine the link relation for retrieving the results of a search operation
You open the URL for a repository as follows:
Request
GET /dms/r/dee1f3d3-eae8-5d9d-84d8-2d758c5ddc27 Accept: application/hal+json
The JSON object for the repository contains the searchresult
link relation with placeholders for the values used to perform the search for DMS objects.
Response
{ _links: { searchresult: { href: "/dms/r/dee1f3d3-eae8-5d9d-84d8-2d758c5ddc27/sr/{?objectdefinitionids,fulltext,properties,propertysort,ascending,showdetails}" templated: true } }, id: "dee1f3d3-eae8-5d9d-84d8-2d758c5ddc27" }
Specifying response control parameters
Use the following parameters to control the system response when viewing the results:
Parameter | Description |
---|---|
| If the search operation finds a single document, this parameter specifies whether this document is displayed directly in the detail view (default value: |
| Specifies the ID of the property that is used to sort the result. If no sort property is specified, the default sort order using the Last modified sort criterion is applied.
You can also sort the result list based on an advanced property. The ID of the property corresponds to the ID (RID) of a property that you can determine for each advanced property in d.3 admin. For additional information about the ID of a property (RID) see the manual about d.3 admin ( |
| Specifies the direction of the sort order.
In case the In addition to this, dossiers are displayed prior to documents in the result list. Within documents and dossiers, the items are sorted by the sorting criterion. |
| Specifies the document ID for which the linked direct child items are searched. |
For descriptions of the objectdefinitionids
, fulltext
and properties
parameters, see the Defining the parameters for a search operation chapter.
Open the URL for the results
Once you have created a URL, you can then open the results as follows:
Request
GET /dms/r/dee1f3d3-eae8-5d9d-84d8-2d758c5ddc27/sr/?objectdefinitionids=["RECH"]&fulltext=Mustermann&properties={"227":["KND001"]} Accept: text/html
The result of the search operation is then loaded.
Note
You must encode the URL parameters (e.g. spaces in %20
). The length of the encoded query parameter is limited to 2000 characters.
Use cases for various result lists (not encoded):
Searching across a category: Add the part
objectdefinitionids=["<category ID>"]
to the URL.
https://
<Base address>/dms/r/
<RepositoryID>/sr/?fulltext=5353&objectdefinitionids=["RECH"]
Searching across several categories: Add the part
objectdefinitionids=[
"<category ID>","<category ID>"
] to the URL.
https://
<Base address>/dms/r/<RepositoryID>
/s/?fulltext=5353&objectdefinitionids=["RECH"]
Searching for PDF documents restricted to the file type: Complete the URL by the part
properties={"property_filetype":["<File type>"]}
.
https://
<Base address>/dms/r/<RepositoryID>
/s/?fulltext=test&properties={"property_filetype":["pdf"]}
Searching for an alphanumeric property: Add
properties={"227":["KND001"]}
(not encoded) to theproperties
parameter in the URL to find the property field with the RID 227 (customer number) and the value"KND001"
as the customer number.
https://
<Base address>/dms/r/<RepositoryID>
/s/?objectdefinitionids=["RECH"]&fulltext=&properties={"227":["KND001"]}
Searching for multiple properties: Add
properties={"227":["KND001"],"231":["|-100"]}
(not encoded) to theproperties
parameter in the URL to find the property field with the RID 227 (customer number) with the value"KND001"
and the property field with the RID 231 (invoice amount) with a value lower than or equal to 100.
https://
<Base address>/dms/r/<RepositoryID>
/s/?objectdefinitionids=["RECH"]&fulltext=&properties={"227":["KND001"],"231":["|-100"]}
Defining the sort order of the result list based on the title: Complete the URL by the part
propertysort=property_caption
.
https://<Base address>
/dms/r/
<RepositoryID>/sr/?fulltext=&objectdefinitionids=["RECH"]&propertysort=property_caption
As response you will receive the HTML page with the result list. If there is an error, you will receive an HTML page that describes the error in more detail. If errors occur, you must correct the incorrect request.